349874 Fix typos in source code
349828 memcpy intercepts memmove causing src/dst overlap error (ppc64 ld.so)
349941 di_notify_mmap might create wrong start/size DebugInfoMapping
+350809 Fix none/tests/async-sigs for Solaris
350811 Remove reference to --db-attach which has been removed.
n-i-bz Provide implementations of certain compiler builtins to support
compilers who may not provide those
{
}
+static void install_handler(int sig, void (*sig_handler)(int))
+{
+ struct sigaction sa;
+ sa.sa_handler = sig_handler;
+ sigemptyset(&sa.sa_mask);
+ sa.sa_flags = 0;
+ sigaction(sig, &sa, 0);
+}
+
/* Kill our child, but use a separate kill command. This is so that
it's running independently of Valgrind, and so is async with
respect to thread scheduling. */
// - otherwise, wait in client code (by spinning).
// The alarm() calls is so that if something breaks, we don't get stuck.
if (pid == 0) {
- struct sigaction sa;
- sa.sa_handler = handler;
- sigemptyset(&sa.sa_mask);
- sa.sa_flags = 0;
- sigaction(caughtsig, &sa, 0);
+ install_handler(caughtsig, handler);
alarm(10);
for (;;)
int main()
{
+ /* Restore default behaviour of SIGHUP when forked from cron. */
+ install_handler(SIGHUP, SIG_DFL);
+
test(/*non-blocked*/0, /* sync*/SIGSEGV, /* sync*/SIGBUS);
test(/*non-blocked*/0, /* sync*/SIGSEGV, /*async*/SIGHUP);
test(/*non-blocked*/0, /*async*/SIGUSR1, /* sync*/SIGBUS);