Skip to content

Commit 109670c

Browse files
author
Don Brady
committed
stbtrace should have nonzero exit code on failure [Backport of #17 to 6.0.3.0]
1 parent f19c981 commit 109670c

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

cmd/stbtrace.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,12 @@
133133
script = template.render()
134134
if args.bcc:
135135
print (script)
136+
exit(0)
136137
else:
137138
try:
138139
exec(script)
139-
except BaseException as e:
140+
except KeyboardInterrupt:
141+
exit(0)
142+
except Exception as e:
140143
print (e)
144+
exit(1)

0 commit comments

Comments
 (0)