Created
June 28, 2019 17:40
-
-
Save hotsphink/340d4834f61c748a3c318250488ab0be to your computer and use it in GitHub Desktop.
mkgist-created gist
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/tools/rb/fix_stack_using_bpsyms.py b/tools/rb/fix_stack_using_bpsyms.py | |
--- a/tools/rb/fix_stack_using_bpsyms.py | |
+++ b/tools/rb/fix_stack_using_bpsyms.py | |
@@ -180,17 +180,19 @@ def addressToSymbol(file, address, symbo | |
p = getSymbolFile(file, symbolsDir) | |
if p: | |
return p.addrToSymbol(address) | |
else: | |
return "" | |
# Matches lines produced by NS_FormatCodeAddress(). | |
-line_re = re.compile("^(.*#\d+: )(.+)\[(.+) \+(0x[0-9A-Fa-f]+)\](.*)$") | |
+#line_re = re.compile("^(.*#\d+: )(.+)\[(.+) \+(0x[0-9A-Fa-f]+)\](.*)$") | |
+line_re = re.compile(r'^(.*#\d+: )(.*\\)?([^\\]+) \+ (0x[0-9A-Fa-f]+)(.*)$') | |
+# "OLJ": "#00: Z:\\\\\\\\task_1561676930\\\\\\\\build\\\\\\\\application\\\\\\\\firefox\\\\\\\\xul.dll + 0x4b0bfe3", | |
def fixSymbols(line, symbolsDir, jsonEscape=False): | |
result = line_re.match(line) | |
if result is not None: | |
(before, fn, file, address, after) = result.groups() | |
address = int(address, 16) | |
symbol = addressToSymbol(file, address, symbolsDir) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment