mib created this revision.
mib added reviewers: bulbazord, JDevlieghere.
mib added a project: LLDB.
Herald added a project: All.
mib requested review of this revision.
Herald added a subscriber: lldb-commits.
This patch should address the crashes when parsing a the crash report
frame dictionary.
If the crash report is not symbolicated, the `symbolLocation` key will
be missing. In that case, we should just use the `imageOffset`.
rdar://109836386
Signed-off-by: Med Ismail Bennani <[email protected]>
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D151844
Files:
lldb/examples/python/crashlog.py
Index: lldb/examples/python/crashlog.py
===================================================================
--- lldb/examples/python/crashlog.py
+++ lldb/examples/python/crashlog.py
@@ -596,9 +596,11 @@
image_addr = self.get_used_image(image_id)["base"]
pc = image_addr + frame_offset
- if "symbol" in json_frame:
- symbol = json_frame["symbol"]
- location = int(json_frame["symbolLocation"])
+ if 'symbol' in json_frame:
+ symbol = json_frame['symbol']
+ location = 0
+ if "symbolLocation" in json_frame and
json_frame["symbolLocation"]:
+ location = int(json_frame["symbolLocation"])
image = self.images[image_id]
image.symbols[symbol] = {
"name": symbol,
Index: lldb/examples/python/crashlog.py
===================================================================
--- lldb/examples/python/crashlog.py
+++ lldb/examples/python/crashlog.py
@@ -596,9 +596,11 @@
image_addr = self.get_used_image(image_id)["base"]
pc = image_addr + frame_offset
- if "symbol" in json_frame:
- symbol = json_frame["symbol"]
- location = int(json_frame["symbolLocation"])
+ if 'symbol' in json_frame:
+ symbol = json_frame['symbol']
+ location = 0
+ if "symbolLocation" in json_frame and json_frame["symbolLocation"]:
+ location = int(json_frame["symbolLocation"])
image = self.images[image_id]
image.symbols[symbol] = {
"name": symbol,
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits