summaryrefslogtreecommitdiff
path: root/alot/helper.py
diff options
context:
space:
mode:
authorPatrick Totzke <patricktotzke@gmail.com>2013-06-24 14:00:14 +0100
committerPatrick Totzke <patricktotzke@gmail.com>2013-07-07 18:06:17 +0100
commitf2e51797f6398f51e248908b3006be2e978e1fea (patch)
treed7bf64bde9111128fa55213cc89cad05e301aee4 /alot/helper.py
parent80040fc8b076a612cc3d052cd809eb2fb27972c7 (diff)
fix: call_cmd properly read return value from...
subprocess.CalledProcessError
Diffstat (limited to 'alot/helper.py')
-rw-r--r--alot/helper.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/alot/helper.py b/alot/helper.py
index f2457aed..c5820b8c 100644
--- a/alot/helper.py
+++ b/alot/helper.py
@@ -312,7 +312,7 @@ def call_cmd(cmdlist, stdin=None):
out = subprocess.check_output(cmdlist)
except subprocess.CalledProcessError as e:
err = e.output
- ret = -1
+ ret = e.returncode
except OSError as e:
err = e.strerror
ret = e.errno