+2006-12-14 Jakub Jelinek <jakub@redhat.com>
+
+ * misc/tst-pselect.c (do_test): Fix sigblock argument.
+
+2006-12-14 Ulrich Drepper <drepper@redhat.com>
+
+ * misc/tst-pselect.c (do_test): Make sure the helper process is
+ terminating when the test is aborted.
+
2006-12-13 Ulrich Drepper <drepper@redhat.com>
[BZ #2337]
return 1;
}
- if (sigblock (SIGUSR1) != 0)
+ sa.sa_handler = SIG_IGN;
+ sa.sa_flags = SA_NOCLDWAIT;
+
+ if (sigaction (SIGCHLD, &sa, NULL) != 0)
+ {
+ puts ("2nd sigaction failed");
+ return 1;
+ }
+
+ if (sigblock (sigmask (SIGUSR1)) != 0)
{
puts ("sigblock failed");
return 1;
struct timespec to = { .tv_sec = 0, .tv_nsec = 500000000 };
+ pid_t parent = getpid ();
pid_t p = fork ();
if (p == 0)
{
int e;
do
{
+ if (getppid () != parent)
+ exit (2);
+
errno = 0;
e = pselect (fds[0][0] + 1, &rfds, NULL, NULL, &to, &ss);
}
return 1;
}
- if (TEMP_FAILURE_RETRY (waitpid (p, NULL, 0)) != p)
- {
- puts ("waitpid failed");
- return 1;
- }
-
return 0;
}