Index: lit/tools/lldb-mi/target/inputs/target-select-so-path.py =================================================================== --- lit/tools/lldb-mi/target/inputs/target-select-so-path.py +++ lit/tools/lldb-mi/target/inputs/target-select-so-path.py @@ -19,7 +19,7 @@ debugserver_proc = subprocess.Popen(debugserver.split()) lldbmi_proc = subprocess.Popen(lldbmi, stdin=subprocess.PIPE, stdout=subprocess.PIPE, shell=True) -filecheck_proc = subprocess.Popen(filecheck, stdin=lldbmi_proc.stdout, +filecheck_proc = subprocess.Popen(filecheck, stdin=subprocess.PIPE, shell=True) # Get a tcp port chosen by debugserver. @@ -32,8 +32,8 @@ # Replace '$PORT' with a free port number and pass # test's content to lldb-mi. lldbmi_proc.stdin.write(f.read().replace('$PORT', port)) - lldbmi_proc.wait() - filecheck_proc.wait() + out, err = lldbmi_proc.communicate() + filecheck_proc.stdin.write(out) debugserver_proc.kill() exit(filecheck_proc.returncode)