diff options
Diffstat (limited to 'chrome/app')
-rw-r--r-- | chrome/app/chrome_dll_main.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/chrome/app/chrome_dll_main.cc b/chrome/app/chrome_dll_main.cc index ad9c77b..c41c95b 100644 --- a/chrome/app/chrome_dll_main.cc +++ b/chrome/app/chrome_dll_main.cc @@ -201,6 +201,10 @@ static void SetUpGLibLogHandler() { } #endif // defined(OS_LINUX) +#if defined(OS_WIN) +extern "C" int _set_new_mode(int); +#endif + // Register the invalid param handler and pure call handler to be able to // notify breakpad when it happens. void RegisterInvalidParamHandler() { @@ -209,6 +213,8 @@ void RegisterInvalidParamHandler() { _set_purecall_handler(PureCall); // Gather allocation failure. std::set_new_handler(&OnNoMemory); + // Also enable the new handler for malloc() based failures. + _set_new_mode(1); #endif } |