summaryrefslogtreecommitdiffstats
path: root/py/mock/exception.py
diff options
context:
space:
mode:
authorMichael E Brown <michael_e_brown@dell.com>2008-01-20 13:30:41 -0600
committerMichael E Brown <michael_e_brown@dell.com>2008-01-20 13:30:41 -0600
commit5aaa59800cae18440c1ba6caca5800e45b3ff5fa (patch)
tree5ff0a59f1718f0afca5bcaa1f88bb9dd383e001c /py/mock/exception.py
parent7589279b856ae73eb26fc728a38a58edbe06d94c (diff)
downloadmock-5aaa59800cae18440c1ba6caca5800e45b3ff5fa.tar.gz
mock-5aaa59800cae18440c1ba6caca5800e45b3ff5fa.tar.xz
mock-5aaa59800cae18440c1ba6caca5800e45b3ff5fa.zip
convert mock.util.do() to use subprocess.Popen() rather than raw fork/exec.\nThis cleans up the code considerably. Also, start reducing the places where we use a shell in the subcommand.
Diffstat (limited to 'py/mock/exception.py')
-rw-r--r--py/mock/exception.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/py/mock/exception.py b/py/mock/exception.py
index b6d6282..d02bddb 100644
--- a/py/mock/exception.py
+++ b/py/mock/exception.py
@@ -19,8 +19,8 @@ class Error(Exception):
Exception.__init__(self)
self.msg = msg
self.resultcode = 1
- if status is not None and os.WIFEXITED(status):
- self.resultcode = os.WEXITSTATUS(status)
+ if status is not None:
+ self.resultcode = status
def __str__(self):
return self.msg