fix(#989): stop the use-after-free crash when the Windows app closes
Crash A of #984. windowManager.destroy() in window_manager 0.5.2 only posts WM_QUIT, so WM_DESTROY never fires and OnDestroy never nulls the controller. The empty ~FlutterWindow then let ~unique_ptr delete the controller without nulling it first; a message arriving mid-teardown (accessibility, text input) went through MessageHandler into the half-destroyed view and FlutterWindowsView::GetEngine read freed memory. Symbolized from crash dumps at flutter_windows.dll+0x1d7b0. - ~FlutterWindow moves the controller out before destroying it, so the MessageHandler guard holds on every quit path. - main.cpp scopes the window so it is destroyed before CoUninitialize. Crash B (BLE plugin unhandled C++ exception) and the link drops stay on #984. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>feat/842-sync-is-truth
parent
5b061924c7
commit
bf392162ab
Loading…
Reference in new issue