Skip to content

sentry_options_set_transport_thread_name is not set as thread_name for the transport (effect: No thread name is set at all) #1420

@JanFellner

Description

@JanFellner

Using sentry 0.11.3 (rechecked with master, same behaviour) on Windows
Setting a thread name with

sentry_options_set_transport_thread_name(options, "sentry::worker_thread");

does not set a thread name when i debug my application.

If i follow the callstack i see no place where this value is copied

sentry_init(options);
sentry__transport_startup(transport, options);
transport->startup_func(options, transport-state);
sentry__winhttp_transport_start(options, transport_state)

I see the value in sentry_bgworker_s but it looks like it is never filled with the value from opts

struct sentry_bgworker_s {
    sentry_threadid_t thread_id;
    char *thread_name;
    sentry_cond_t submit_signal;
    sentry_cond_t done_signal;
    sentry_mutex_t task_lock;
    sentry_bgworker_task_t *first_task;
    sentry_bgworker_task_t *last_task;
    void *state;
    void (*free_state)(void *state);
    long refcount;
    long running;
};

Metadata

Metadata

Assignees

Projects

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions