Win32: fix destruction order issue leading to crash on close.

pull/409/head
whitequark 2019-05-13 09:02:54 +00:00
parent f07e975db1
commit c44a471649
1 changed files with 4 additions and 0 deletions

View File

@ -639,6 +639,10 @@ public:
}
~WindowImplWin32() {
// Make sure any of our child windows get destroyed before we call DestroyWindow, or their
// own destructors may fail.
menuBar.reset();
sscheck(DestroyWindow(hWindow));
#if defined(HAVE_SPACEWARE)
if(hSpaceWare != SI_NO_HANDLE) {