Commit f9956f91 authored by Daniel Stan's avatar Daniel Stan

subprocess: don't use wait()

http://docs.python.org/2/library/subprocess.html#subprocess.Popen.wait

Je n'avais pas lu le warning ...
parent fc40d2e6
......@@ -300,9 +300,11 @@ def remote_command(options, command, arg=None, stdin_contents=None):
proc = remote_proc(options, command, arg)
if stdin_contents is not None:
proc.stdin.write(json.dumps(stdin_contents))
proc.stdin.close()
ret = proc.wait()
raw_out = proc.stdout.read()
proc.stdin.flush()
raw_out, raw_err = proc.communicate()
ret = proc.returncode
if ret != 0:
if not options.quiet:
print((u"Mauvais code retour côté serveur, voir erreur " +
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment