From e3fa9c9ab6a2b1f9955c457f413ddc81d0c1f3ff Mon Sep 17 00:00:00 2001 From: Patrick Welche Date: Fri, 27 Sep 2013 10:09:32 +0100 Subject: [PATCH] Only use SA_RESTART if it exists Fixes build on QNX (and possibly HPUX given Bug 168352) Patch essentially from pkgsrc devel/glib2/patches/patch-ai https://bugzilla.gnome.org/show_bug.cgi?id=583321 --- glib/gmain.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/glib/gmain.c b/glib/gmain.c index 738e69c..4edf05e 100644 --- a/glib/gmain.c +++ b/glib/gmain.c @@ -4963,7 +4963,11 @@ ref_unix_signal_handler_unlocked (int signum) struct sigaction action; action.sa_handler = g_unix_signal_handler; sigemptyset (&action.sa_mask); +#ifdef SA_RESTART action.sa_flags = SA_RESTART | SA_NOCLDSTOP; +#else + action.sa_flags = SA_NOCLDSTOP; +#endif sigaction (signum, &action, NULL); } } -- 2.7.4