mirror of
https://github.com/blender/blender
synced 2026-09-29 04:37:17 +03:00
Fix occasional crash on exit under Wayland
pthread_cancel was sometimes called once the thread had exited, resolve this by having the function wait to be canceled.
This commit is contained in:
parent
8a4ab1b3fe
commit
c007e6a346
1 changed files with 7 additions and 0 deletions
|
|
@ -5470,6 +5470,13 @@ static void *gwl_display_event_thread_fn(void *display_voidp)
|
|||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* Wait until the main thread cancels this thread, otherwise this thread may exit
|
||||
* before cancel is called, causing a crash on exit. */
|
||||
while (true) {
|
||||
pause();
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue