History

scripts/decode_stacktrace: strip basepath from all paths

Currently the basepath is removed only from the beginning of the string. When the symbol is inlined and there's multiple line outputs of addr2line, only the first line would have basepath removed. Change to remove the basepath prefix from all lines.

Pi-Hsun Shih committed 6 years ago

Commit d1787701 parent 2910c591 file · +2 −2Browse files

Showing the changes to scripts/decode_stacktrace.sh (1 of 1 file). Show all

Unified · Split

scripts/decode_stacktrace.sh+2−2
@@ -87,8 +87,8 @@ parse_symbol() { · 86 unmodified lines
8787 return
8888 fi
8989
90− # Strip out the base of the path
91− code=${code#$basepath/}
90+ # Strip out the base of the path on each line
91+ code=$(while read -r line; do echo "${line#$basepath/}"; done <<< "$code")
9292
9393 # In the case of inlines, move everything to same line
9494 code=${code//$'\n'/' '}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t