Skip to content

Commit e4105bc

Browse files
committed
Resolve maint-c post merge shutdown issue #2
1 parent 9927ac2 commit e4105bc

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

indra/llwindow/llwindowwin32.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,6 +403,7 @@ struct LLWindowWin32::LLWindowWin32Thread : public LL::ThreadPool
403403
// until after some graphics setup. See SL-20177. -Cosmic,2023-09-18
404404
bool mGLReady = false;
405405
bool mGotGLBuffer = false;
406+
bool mShuttingDown = false;
406407
};
407408

408409

@@ -4576,12 +4577,14 @@ inline LLWindowWin32::LLWindowWin32Thread::LLWindowWin32Thread()
45764577

45774578
void LLWindowWin32::LLWindowWin32Thread::close()
45784579
{
4579-
if (mWindowHandleThrd)
4580+
LL::ThreadPool::close();
4581+
if (!mShuttingDown)
45804582
{
45814583
LL_WARNS() << "Closing window thread without using destroy_window_handler" << LL_ENDL;
45824584
// Workaround for SL-18721 in case window closes too early and abruptly
45834585
LLSplashScreen::show();
45844586
LLSplashScreen::update("..."); // will be updated later
4587+
mShuttingDown = true;
45854588
}
45864589
}
45874590

@@ -4793,6 +4796,8 @@ void LLWindowWin32::LLWindowWin32Thread::wakeAndDestroy()
47934796
return;
47944797
}
47954798

4799+
mShuttingDown = true;
4800+
47964801
// Make sure we don't leave a blank toolbar button.
47974802
// Also hiding window now prevents user from suspending it
47984803
// via some action (like dragging it around)

0 commit comments

Comments
 (0)