mirror of
https://git.mirrors.martin98.com/https://github.com/SoftFever/OrcaSlicer.git
synced 2025-08-16 11:05:57 +08:00
FIX: Direct crash when bad_alloc
Change-Id: If8e26218efa1750a7cbdced4f4b7db19d3a14db0
This commit is contained in:
parent
ec94c46665
commit
f1a99020f6
@ -3014,6 +3014,10 @@ extern "C" {
|
|||||||
//AddVectoredExceptionHandler(1, CBaseException::UnhandledExceptionFilter);
|
//AddVectoredExceptionHandler(1, CBaseException::UnhandledExceptionFilter);
|
||||||
SET_DEFULTER_HANDLER();
|
SET_DEFULTER_HANDLER();
|
||||||
#endif
|
#endif
|
||||||
|
std::set_new_handler([]() {
|
||||||
|
int *a = nullptr;
|
||||||
|
*a = 0;
|
||||||
|
});
|
||||||
// Call the UTF8 main.
|
// Call the UTF8 main.
|
||||||
return CLI().run(argc, argv_ptrs.data());
|
return CLI().run(argc, argv_ptrs.data());
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user