Bug 1267329 - part 2 - Record the memory information for the minidumps on Windows. r=ted, a=gchang
authorTing-Yu Chou <janus926@gmail.com>
Thu, 30 Jun 2016 08:59:02 +0800
changeset 342001 c1cee3d0990479215fe757140aaaad3916c362fc
parent 342000 01b86a0a32b226c5ef875e69910c3244c05a7fe6
child 342002 df749e7bf392dc10c34fa4a57685f03aff8468ae
push id1183
push userraliiev@mozilla.com
push dateMon, 05 Sep 2016 20:01:49 +0000
treeherdermozilla-release@3148731bed45 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted, gchang
bugs1267329
milestone49.0a2
Bug 1267329 - part 2 - Record the memory information for the minidumps on Windows. r=ted, a=gchang
toolkit/crashreporter/nsExceptionHandler.cpp
--- a/toolkit/crashreporter/nsExceptionHandler.cpp
+++ b/toolkit/crashreporter/nsExceptionHandler.cpp
@@ -3860,17 +3860,21 @@ bool TakeMinidump(nsIFile** aResult, boo
 
   // capture the dump
   if (!google_breakpad::ExceptionHandler::WriteMinidump(
          dump_path,
 #ifdef XP_MACOSX
          true,
 #endif
          PairedDumpCallback,
-         static_cast<void*>(aResult))) {
+         static_cast<void*>(aResult)
+#ifdef XP_WIN32
+         , GetMinidumpType()
+#endif
+      )) {
     return false;
   }
 
   if (aMoveToPending) {
     MoveToPending(*aResult, nullptr, nullptr);
   }
   return true;
 }
@@ -3901,33 +3905,40 @@ CreateMinidumpsAndPair(ProcessHandle aTa
 
   // dump the target
   nsCOMPtr<nsIFile> targetMinidump;
   if (!google_breakpad::ExceptionHandler::WriteMinidumpForChild(
          aTargetPid,
          targetThread,
          dump_path,
          PairedDumpCallbackExtra,
-         static_cast<void*>(&targetMinidump)))
+         static_cast<void*>(&targetMinidump)
+#ifdef XP_WIN32
+         , GetMinidumpType()
+#endif
+      ))
     return false;
 
   nsCOMPtr<nsIFile> targetExtra;
   GetExtraFileForMinidump(targetMinidump, getter_AddRefs(targetExtra));
 
   // If aIncomingDumpToPair isn't valid, create a dump of this process.
   nsCOMPtr<nsIFile> incomingDump;
   if (aIncomingDumpToPair == nullptr) {
     if (!google_breakpad::ExceptionHandler::WriteMinidump(
         dump_path,
 #ifdef XP_MACOSX
         true,
 #endif
         PairedDumpCallback,
-        static_cast<void*>(&incomingDump))) {
-
+        static_cast<void*>(&incomingDump)
+#ifdef XP_WIN32
+        , GetMinidumpType()
+#endif
+        )) {
       targetMinidump->Remove(false);
       targetExtra->Remove(false);
       return false;
     }
   } else {
     incomingDump = aIncomingDumpToPair;
   }
 
@@ -3967,17 +3978,21 @@ CreateAdditionalChildMinidump(ProcessHan
 
   // dump the child
   nsCOMPtr<nsIFile> childMinidump;
   if (!google_breakpad::ExceptionHandler::WriteMinidumpForChild(
          childPid,
          childThread,
          dump_path,
          PairedDumpCallback,
-         static_cast<void*>(&childMinidump))) {
+         static_cast<void*>(&childMinidump)
+#ifdef XP_WIN32
+         , GetMinidumpType()
+#endif
+      )) {
     return false;
   }
 
   RenameAdditionalHangMinidump(childMinidump, parentMinidump, name);
 
   return true;
 }