Skip to content

Commit

Permalink
Avoid using os.system since it serializes threads on macosx.
Browse files Browse the repository at this point in the history
  • Loading branch information
ktf committed Aug 10, 2011
1 parent af00792 commit a757dd2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Configuration/PyReleaseValidation/python/WorkFlowRunner.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

from Configuration.PyReleaseValidation import WorkFlow
import os,time
from subprocess import Popen

class WorkFlowRunner(Thread):
def __init__(self, wf):
Expand Down Expand Up @@ -30,7 +31,8 @@ def doCmd(self, cmd, dryRun=False):

ret = 0
if not dryRun:
ret = os.system(cmd)
p = Popen(cmd, shell=True)
ret = os.waitpid(p.pid, 0)[1]
if ret != 0:
print "ERROR executing ",cmd,'ret=', ret

Expand Down

0 comments on commit a757dd2

Please sign in to comment.