Browse code

Merge "Wait for command in worlddump"

Jenkins authored on 2015/07/17 01:08:00
Showing 1 changed files
... ...
@@ -21,9 +21,9 @@ import datetime
21 21
 import fnmatch
22 22
 import os
23 23
 import os.path
24
+import subprocess
24 25
 import sys
25 26
 
26
-from subprocess import Popen
27 27
 
28 28
 def get_options():
29 29
     parser = argparse.ArgumentParser(
... ...
@@ -47,7 +47,10 @@ def _dump_cmd(cmd):
47 47
     print cmd
48 48
     print "-" * len(cmd)
49 49
     print
50
-    Popen(cmd, shell=True)
50
+    try:
51
+        subprocess.check_call(cmd, shell=True)
52
+    except subprocess.CalledProcessError:
53
+        print "*** Failed to run: %s" % cmd
51 54
 
52 55
 
53 56
 def _header(name):