]> xenbits.xensource.com Git - xenrt-citrix/xenrt.git/commitdiff
Fix quoting
authorJohn Dilley <john.dilley@citrix.com>
Thu, 15 Oct 2015 07:38:51 +0000 (08:38 +0100)
committerJohn Dilley <john.dilley@citrix.com>
Thu, 15 Oct 2015 07:38:51 +0000 (08:38 +0100)
control/site-controller.in

index 4bc9e4d36fb5f4b971980bde3914932abd7a4cdd..78c027d2724af4926c579148b1183235c2d9bfec 100755 (executable)
@@ -135,7 +135,7 @@ def fqdn(host):
 def killJob(jobid):
     global _sharedir
     resdir = os.popen("realpath %s/results/jobs/%s" % (_sharedir, jobid)).read().strip()
-    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$" % resdir)
+    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$'" % resdir)
     for l in f.readlines():
         m = re.match("main.py\s+(\d+)", l)
         if m:
@@ -145,7 +145,7 @@ def killJob(jobid):
             os.system(cmd)
             time.sleep(5)
     f.close()
-    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$" % resdir)
+    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$'" % resdir)
     pids = []
     for l in f.readlines():
         m = re.match("\S+\s+(\d+)", l)
@@ -160,7 +160,7 @@ def checkJobRunning(jobid):
     pid = None
     global _sharedir
     resdir = os.popen("realpath %s/results/jobs/%s" % (_sharedir, jobid)).read().strip()
-    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$" % resdir)
+    f = os.popen("sudo ls -l /proc/*/cwd |  grep  ' %s$'" % resdir)
     for l in f.readlines():
         m = re.match("main.py\s+(\d+)", l)
         if m: