End the Process if Closing OrcaSlicer Takes More Than 30 Seconds (#16766)

Last resort for code that never returns while the app closes, such as
plugin code, vendor libraries or a lost network call. Once closing can
no longer be vetoed, a watchdog thread waits 30 seconds, logs that the
app did not finish closing and ends the process with std::_Exit. The app
config is saved on idle and again in MainFrame::shutdown, so little is
lost.
This commit is contained in:
HanifKoh authored and GitHub committed 2026-10-23 19:21:22 +08:00
1 parent 30ceeee18d
commit 14da40e3a7
3 files changed
+33

No files matched your search

+1
View File
@@ -732,6 +732,7 @@ DPIFrame(NULL, wxID_ANY, "", wxDefaultPosition, wxDefaultSize, BORDERLESS_FRAME_
MarkdownTip::ExitTip();
// Prevent queued selection/UI refresh work from running as normal during reset.
wxGetApp().set_closing(true);
wxGetApp().start_exit_watchdog();
m_plater->reset();
this->shutdown();