git://git.onelab.eu
/
lxc-userspace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Tweaked return code handling to use the usual Python method
[lxc-userspace.git]
/
lxcsu
diff --git
a/lxcsu
b/lxcsu
index
baf0e97
..
7a4ed1b
100644
(file)
--- a/
lxcsu
+++ b/
lxcsu
@@
-124,7
+124,5
@@
if (pid == 0):
os.environ['SHELL'] = '/bin/sh'
os.execv('/usr/sbin/capsh',exec_args)
else:
- (r_pid,combined)=os.waitpid(pid,0)
- retcod=combined/256
- sys.exit(retcod)
-
+ _,status = os.waitpid(pid,0)
+ exit(os.WEXITSTATUS(status))