From: Jan S. <jst...@re...> - 2012-06-05 11:29:51
|
If child gets killed before it completes signal(SIGTERM, SIG_DFL), then kill(childpid, SIGTERM) causes testcase to fail, because it is caught by LTP def_handler. For example: dio_sparse 0 TINFO : Dirtying free blocks dio_sparse 0 TINFO : Starting I/O tests dio_sparse 1 TBROK : unexpected signal 15 received (pid = 10319). dio_sparse 2 TBROK : Remaining cases broken ... Fix this by adding semaphore to wait until all children complete signal() before killing them. Signed-off-by: Jan Stancek <jst...@re...> --- testcases/kernel/io/ltp-aiodio/dio_sparse.c | 43 +++++++++++++++++++++++++- 1 files changed, 41 insertions(+), 2 deletions(-) |