Bug 1174250: Allow the CommitHook to fail without crashing. r=glandium
authorDavid Major <dmajor@mozilla.com>
Tue, 15 Sep 2015 13:53:38 -0400
changeset 262635 408c024f3dc010f61ac698b505f268999448fe8a
parent 262634 5ee49f58051365db87c1fc1a3d1d7b278da21aa2
child 262636 27cdeffa4ae126a34f50413a73fffb66b272b114
push id29378
push userkwierso@gmail.com
push dateWed, 16 Sep 2015 00:16:30 +0000
treeherdermozilla-central@df10a3f6060f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersglandium
bugs1174250
milestone43.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1174250: Allow the CommitHook to fail without crashing. r=glandium
memory/build/jemalloc_config.cpp
--- a/memory/build/jemalloc_config.cpp
+++ b/memory/build/jemalloc_config.cpp
@@ -116,17 +116,17 @@ private:
   static bool
   CommitHook(void* chunk, size_t size, size_t offset, size_t length,
              unsigned arena_ind)
   {
     void* addr = reinterpret_cast<void*>(
       reinterpret_cast<uintptr_t>(chunk) + static_cast<uintptr_t>(offset));
 
     if (!VirtualAlloc(addr, length, MEM_COMMIT, PAGE_READWRITE))
-      MOZ_CRASH();
+      return true;
 
     return false;
   }
 
   static bool
   DecommitHook(void* chunk, size_t size, size_t offset, size_t length,
                unsigned arena_ind)
   {