summaryrefslogtreecommitdiffstats
path: root/share/extensions/run_command.py
diff options
context:
space:
mode:
authorJabiertxof <jtx@jtx>2017-01-23 22:40:10 +0000
committerJabiertxof <jtx@jtx>2017-01-23 22:40:10 +0000
commit8a7004fa550bb1d5eff8ca6ce716b391ea8d9ff8 (patch)
tree598923b2b554aeaf77457a83c399c616a7ecc162 /share/extensions/run_command.py
parentRemove unnecesatry text parameter (diff)
parentfix nodes reverting back during editing (diff)
downloadinkscape-8a7004fa550bb1d5eff8ca6ce716b391ea8d9ff8.tar.gz
inkscape-8a7004fa550bb1d5eff8ca6ce716b391ea8d9ff8.zip
Add fixes sugested by Martin Owens
(bzr r15392.1.7)
Diffstat (limited to 'share/extensions/run_command.py')
-rwxr-xr-xshare/extensions/run_command.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/share/extensions/run_command.py b/share/extensions/run_command.py
index 7012c4274..950e9ed7c 100755
--- a/share/extensions/run_command.py
+++ b/share/extensions/run_command.py
@@ -61,8 +61,11 @@ def run(command_format, prog_name):
except ImportError:
# shouldn't happen...
msg = "Neither subprocess.Popen nor popen2.Popen3 is available"
- if rc and msg is None:
- msg = "%s failed:\n%s\n%s\n" % (prog_name, out, err)
+ if msg is None:
+ if rc:
+ msg = "%s failed:\n%s\n%s\n" % (prog_name, out, err)
+ elif err:
+ sys.stderr.write("%s executed but logged the following error:\n%s\n%s\n" % (prog_name, out, err))
except Exception, inst:
msg = "Error attempting to run %s: %s" % (prog_name, str(inst))