diff src/sighandlers.cc @ 10344:65974373505a

Do not use SIGALRM unconditinally.
author Michael Goffioul <michael.goffioul@gmail.com>
date Sun, 21 Feb 2010 17:40:13 +0000
parents 57a59eae83cc
children 479cc8a0a846
line wrap: on
line diff
--- a/src/sighandlers.cc	Sun Feb 21 17:37:06 2010 +0000
+++ b/src/sighandlers.cc	Sun Feb 21 17:40:13 2010 +0000
@@ -178,15 +178,20 @@
   act.sa_handler = handler;
   act.sa_flags = 0;
 
+#if defined (SIGALRM)
   if (sig == SIGALRM)
     {
 #if defined (SA_INTERRUPT)
       act.sa_flags |= SA_INTERRUPT;
 #endif
     }
+#endif
 #if defined (SA_RESTART)
+#if defined (SIGALRM)
+  else
+#endif
   // FIXME -- Do we also need to explicitly disable SA_RESTART?
-  else if (restart_syscalls)
+  if (restart_syscalls)
     act.sa_flags |= SA_RESTART;
 #endif