mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 19:04:45 +00:00
bug 540627 - provide an environment variable to save minidumps from test runs. r=bsmedberg
--HG-- extra : rebase_source : d53ac17a06eb938e1fcd9a59e409b3467c04fed9
This commit is contained in:
parent
4f49aefd7d
commit
1451ee2e6c
@ -36,7 +36,7 @@
|
||||
#
|
||||
# ***** END LICENSE BLOCK ***** */
|
||||
|
||||
import glob, logging, os, subprocess, sys
|
||||
import glob, logging, os, shutil, subprocess, sys
|
||||
import re
|
||||
|
||||
__all__ = [
|
||||
@ -118,7 +118,13 @@ def checkForCrashes(dumpDir, symbolsPath, testName=None):
|
||||
else:
|
||||
if not os.path.exists(stackwalkPath):
|
||||
print "MINIDUMP_STACKWALK binary not found: %s" % stackwalkPath
|
||||
os.remove(d)
|
||||
dumpSavePath = os.environ.get('MINIDUMP_SAVE_PATH', None)
|
||||
if dumpSavePath:
|
||||
shutil.move(d, dumpSavePath)
|
||||
print "Saved dump as %s" % os.path.join(dumpSavePath,
|
||||
os.path.basename(d))
|
||||
else:
|
||||
os.remove(d)
|
||||
extra = os.path.splitext(d)[0] + ".extra"
|
||||
if os.path.exists(extra):
|
||||
os.remove(extra)
|
||||
|
Loading…
Reference in New Issue
Block a user