There are test environments, where the SIGHUP signal may be either
added to the signal mask or ignored. One example of such environments
is Autotest, which sets the SIGHUP signal to SIG_IGN for its jobs.

Therefore the above test cases hang in that environment because their
parent processes send SIGHUP to terminate the child (and the child ignores it).

I think it will not be a problem to use SIGKILL here instead of SIGHUP, because
SIGKILL can not be caught, blocked, or ignored.
And it does the job - stopping the child - very well :)

Signed-off-by: Stanislav Kholmanskikh <stanislav.kholmansk...@oracle.com>
---
 .../conformance/interfaces/sigaction/10-1.c        |    3 +--
 .../conformance/interfaces/sigaction/11-1.c        |    3 +--
 .../conformance/interfaces/sigaction/9-1.c         |    3 +--
 3 files changed, 3 insertions(+), 6 deletions(-)

diff --git 
a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/10-1.c 
b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/10-1.c
index 1e729f4..e50357b 100644
--- a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/10-1.c
+++ b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/10-1.c
@@ -101,8 +101,7 @@ int main(void)
                        wait_for_notification(CLD_CONTINUED);
                }
 
-               /* POSIX specifies default action to be abnormal termination */
-               kill(pid, SIGHUP);
+               kill(pid, SIGKILL);
                waitpid(pid, &s, 0);
        }
 
diff --git 
a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/11-1.c 
b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/11-1.c
index 804bf9e..73405ea 100644
--- a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/11-1.c
+++ b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/11-1.c
@@ -95,8 +95,7 @@ int main(void)
 
                }
 
-               /* POSIX specifies default action to be abnormal termination */
-               kill(pid, SIGHUP);
+               kill(pid, SIGKILL);
                waitpid(pid, &s, 0);
        }
 
diff --git 
a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/9-1.c 
b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/9-1.c
index 984a0ee..07dbb7b 100644
--- a/testcases/open_posix_testsuite/conformance/interfaces/sigaction/9-1.c
+++ b/testcases/open_posix_testsuite/conformance/interfaces/sigaction/9-1.c
@@ -89,8 +89,7 @@ int main(void)
                        kill(pid, SIGCONT);
                }
 
-               /* POSIX specifies default action to be abnormal termination */
-               kill(pid, SIGHUP);
+               kill(pid, SIGKILL);
                waitpid(pid, &s, 0);
        }
 
-- 
1.7.1


------------------------------------------------------------------------------
Start Your Social Network Today - Download eXo Platform
Build your Enterprise Intranet with eXo Platform Software
Java Based Open Source Intranet - Social, Extensible, Cloud Ready
Get Started Now And Turn Your Intranet Into A Collaboration Platform
http://p.sf.net/sfu/ExoPlatform
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to