+
+ // arm signal handlers; code below may generate signals we want to see
+ if (signal(SIGCHLD, handleSignals) == SIG_ERR)
+ secdebug("SS", "Cannot handle SIGCHLD: errno=%d", errno);
+ if (signal(SIGINT, handleSignals) == SIG_ERR)
+ secdebug("SS", "Cannot handle SIGINT: errno=%d", errno);
+ if (signal(SIGTERM, handleSignals) == SIG_ERR)
+ secdebug("SS", "Cannot handle SIGTERM: errno=%d", errno);
+ if (signal(SIGPIPE, handleSignals) == SIG_ERR)
+ secdebug("SS", "Cannot handle SIGPIPE: errno=%d", errno);
+#if !defined(NDEBUG)
+ if (signal(SIGUSR1, handleSignals) == SIG_ERR)
+ secdebug("SS", "Cannot handle SIGHUP: errno=%d", errno);
+#endif //NDEBUG
+
+ // create the shared memory notification hub
+ new SharedMemoryListener(messagingName, kSharedMemoryPoolSize);