git.samba.org
/
samba.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e79040c
)
samba-tool: Catch exceptions at top-level and exit with correct return value
author
Amitay Isaacs
<amitay@gmail.com>
Thu, 21 Jul 2011 02:32:53 +0000
(12:32 +1000)
committer
Andrew Tridgell
<tridge@samba.org>
Thu, 28 Jul 2011 05:20:52 +0000
(15:20 +1000)
Signed-off-by: Andrew Tridgell <tridge@samba.org>
source4/scripting/bin/samba-tool
patch
|
blob
|
history
diff --git
a/source4/scripting/bin/samba-tool
b/source4/scripting/bin/samba-tool
index f220b82fd984b221ec726f3342ab063f45f4b9e2..c24c0e38dbc2124051eef376b744e4d14dd4d167 100755
(executable)
--- a/
source4/scripting/bin/samba-tool
+++ b/
source4/scripting/bin/samba-tool
@@
-70,4
+70,8
@@
if __name__ == '__main__':
if len(sys.argv) > 2:
args = sys.argv[2:]
- cmd._run("samba-tool.py", command, *args)
+ try:
+ retval = cmd._run("samba-tool", command, *args)
+ sys.exit(retval)
+ except Exception as e:
+ cmd.show_command_error(e)