mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-03 16:03:21 +00:00
Also dump the pid of the process launching through the lldbtest.system(*popenargs, **kwargs) API.
This helps track down possible zombie processes. llvm-svn: 144846
This commit is contained in:
parent
35923d7864
commit
0bd8c311cb
@ -296,6 +296,7 @@ def system(*popenargs, **kwargs):
|
||||
if 'stdout' in kwargs:
|
||||
raise ValueError('stdout argument not allowed, it will be overridden.')
|
||||
process = Popen(stdout=PIPE, stderr=PIPE, *popenargs, **kwargs)
|
||||
pid = process.pid
|
||||
output, error = process.communicate()
|
||||
retcode = process.poll()
|
||||
|
||||
@ -306,6 +307,7 @@ def system(*popenargs, **kwargs):
|
||||
args = list(popenargs)
|
||||
print >> sbuf
|
||||
print >> sbuf, "os command:", args
|
||||
print >> sbuf, "with pid:", pid
|
||||
print >> sbuf, "stdout:", output
|
||||
print >> sbuf, "stderr:", error
|
||||
print >> sbuf, "retcode:", retcode
|
||||
|
Loading…
x
Reference in New Issue
Block a user