]> mj.ucw.cz Git - libucw.git/blobdiff - lib/sighandler.c
CONFIG_INCREMENTAL doesn't belong to the free version
[libucw.git] / lib / sighandler.c
index 3b9dfa0cff7d4792637863480ec9251a651d1a7e..9a76851423eaeaa5ad94c72e30ce1fab2988ee07 100644 (file)
@@ -1,5 +1,5 @@
 /*
- *     Catching of signals and calling callback functions
+ *     UCW Library -- Catching of signals and calling callback functions
  *
  *     (c) 2004, Robert Spalek <robert@ucw.cz>
  */
@@ -26,9 +26,21 @@ signal_handler_internal(int sig)
 void
 handle_signal(int signum, struct sigaction *oldact)
 {
+#if 0
   struct sigaction act;
   bzero(&act, sizeof(act));
   act.sa_handler = signal_handler_internal;
+  act.sa_flags = SA_NOMASK;
   if (sigaction(signum, &act, oldact) < 0)
     die("sigaction: %m");
+#endif
+}
+
+void
+unhandle_signal(int signum, struct sigaction *oldact)
+{
+#if 0
+  if (sigaction(signum, oldact, NULL) < 0)
+    die("sigaction: %m");
+#endif
 }