force_test_exit(): This has been completely ineffective
at stopping test_signal from hanging forever on the Tru64 buildbot. That could be because there's no such thing as signal.SIGALARM. Changed to the idiotic (but standard) signal.SIGALRM instead, and added some more debug output.
This commit is contained in:
parent
08574770c5
commit
8b8c59cf1d
|
@ -10,7 +10,10 @@ if verbose:
|
||||||
x = '-x'
|
x = '-x'
|
||||||
else:
|
else:
|
||||||
x = '+x'
|
x = '+x'
|
||||||
|
|
||||||
pid = os.getpid()
|
pid = os.getpid()
|
||||||
|
if verbose:
|
||||||
|
print "test runner's pid is", pid
|
||||||
|
|
||||||
# Shell script that will send us asynchronous signals
|
# Shell script that will send us asynchronous signals
|
||||||
script = """
|
script = """
|
||||||
|
@ -89,7 +92,8 @@ def force_test_exit():
|
||||||
time.sleep(MAX_DURATION + 5)
|
time.sleep(MAX_DURATION + 5)
|
||||||
print >> sys.__stdout__, ' child should not have to kill parent'
|
print >> sys.__stdout__, ' child should not have to kill parent'
|
||||||
for i in range(3):
|
for i in range(3):
|
||||||
os.kill(pid, signal.SIGALARM)
|
os.kill(pid, signal.SIGALRM)
|
||||||
|
print >> sys.__stdout__, " child sent SIGALRM to", pid
|
||||||
finally:
|
finally:
|
||||||
os._exit(0)
|
os._exit(0)
|
||||||
# In parent (or error)
|
# In parent (or error)
|
||||||
|
|
Loading…
Reference in New Issue