about summary refs log tree commit diff
path: root/pause.c
diff options
context:
space:
mode:
Diffstat (limited to 'pause.c')
-rw-r--r--pause.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/pause.c b/pause.c
new file mode 100644
index 0000000..4825df6
--- /dev/null
+++ b/pause.c
@@ -0,0 +1,20 @@
+#include <unistd.h>
+#include <signal.h>
+
+static void
+nop(int sig)
+{
+}
+
+int
+main()
+{
+  signal(SIGTERM, nop);
+  signal(SIGINT, nop);
+  signal(SIGHUP, SIG_IGN);
+
+  pause();
+
+  return 0;
+}
+