Skip to content

Commit

Permalink
On Windows, name the waiter thread (#2672)
Browse files Browse the repository at this point in the history
  • Loading branch information
notgull authored and kchibisov committed Mar 2, 2023
1 parent 9fb8aaa commit 09bca59
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/platform_impl/windows/event_loop.rs
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,10 @@ impl<T: 'static> EventLoop<T> {

let thread_msg_target = create_event_target_window::<T>();

thread::spawn(move || wait_thread(thread_id, thread_msg_target));
thread::Builder::new()
.name("winit wait thread".to_string())
.spawn(move || wait_thread(thread_id, thread_msg_target))
.expect("Failed to spawn winit wait thread");
let wait_thread_id = get_wait_thread_id();

let runner_shared = Rc::new(EventLoopRunner::new(thread_msg_target, wait_thread_id));
Expand Down

0 comments on commit 09bca59

Please sign in to comment.