mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-02 09:52:27 -04:00
display: lock GraphicsEngine mutex in remove_all_windows()
This commit is contained in:
parent
bfd5fa56fa
commit
4c4288f491
@ -583,6 +583,8 @@ void GraphicsEngine::
|
|||||||
remove_all_windows() {
|
remove_all_windows() {
|
||||||
Thread *current_thread = Thread::get_current_thread();
|
Thread *current_thread = Thread::get_current_thread();
|
||||||
|
|
||||||
|
ReMutexHolder holder(_lock, current_thread);
|
||||||
|
|
||||||
// Let's move the _windows vector into a local copy first, and walk through
|
// Let's move the _windows vector into a local copy first, and walk through
|
||||||
// that local copy, just in case someone we call during the loop attempts to
|
// that local copy, just in case someone we call during the loop attempts to
|
||||||
// modify _windows. I don't know what code would be doing this, but it
|
// modify _windows. I don't know what code would be doing this, but it
|
||||||
|
Loading…
x
Reference in New Issue
Block a user