chiark
/
gitweb
/
~mdw
/
fwd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
268f6af
)
Grammar changes. Also, don't enable SIGINT if it's currently ignored.
author
mdw
<mdw>
Fri, 22 Oct 1999 22:47:50 +0000
(22:47 +0000)
committer
mdw
<mdw>
Fri, 22 Oct 1999 22:47:50 +0000
(22:47 +0000)
fw.c
patch
|
blob
|
blame
|
history
diff --git
a/fw.c
b/fw.c
index 513cb23203b97d25223477c7d511dfcd845ecfcf..e5537fcea88c9d28f6e494fd9ca1e93f18dc8a93 100644
(file)
--- a/
fw.c
+++ b/
fw.c
@@
-1,6
+1,6
@@
/* -*-c-*-
*
/* -*-c-*-
*
- * $Id: fw.c,v 1.
4 1999/10/10 16:46:12
mdw Exp $
+ * $Id: fw.c,v 1.
5 1999/10/22 22:47:50
mdw Exp $
*
* Port forwarding thingy
*
*
* Port forwarding thingy
*
@@
-29,6
+29,9
@@
/*----- Revision history --------------------------------------------------*
*
* $Log: fw.c,v $
/*----- Revision history --------------------------------------------------*
*
* $Log: fw.c,v $
+ * Revision 1.5 1999/10/22 22:47:50 mdw
+ * Grammar changes. Also, don't enable SIGINT if it's currently ignored.
+ *
* Revision 1.4 1999/10/10 16:46:12 mdw
* New resolver to initialize. Also, include options for grammar and
* options references.
* Revision 1.4 1999/10/10 16:46:12 mdw
* New resolver to initialize. Also, include options for grammar and
* options references.
@@
-314,7
+317,7
@@
Exec options\n\
exec.env.[set] var [=] value\n\
\n\
Socket options\n\
exec.env.[set] var [=] value\n\
\n\
Socket options\n\
- socket.conn [=] number\n\
+ socket.conn [=] number
|unlimited|one-shot
\n\
socket.logging [=] yes|no\n\
socket.inet.[allow|deny] [from] address [/ address]\n\
socket.unix.fattr.*\n\
socket.logging [=] yes|no\n\
socket.inet.[allow|deny] [from] address [/ address]\n\
socket.unix.fattr.*\n\
@@
-357,10
+360,20
@@
int main(int argc, char *argv[])
fattr_init(&fattr_global);
scan_create(&sc);
fattr_init(&fattr_global);
scan_create(&sc);
- /* --- Set up some signal handlers --- */
+ /* --- Set up some signal handlers --- *
+ *
+ * Don't enable @SIGINT@ if the caller already disabled it.
+ */
+
+ {
+ struct sigaction sa;
+
+ sig_add(&s_term, SIGTERM, fw_tidy, 0);
+ sigaction(SIGINT, 0, &sa);
+ if (sa.sa_handler != SIG_IGN)
+ sig_add(&s_int, SIGINT, fw_tidy, 0);
+ }
- sig_add(&s_term, SIGTERM, fw_tidy, 0);
- sig_add(&s_int, SIGINT, fw_tidy, 0);
atexit(fw_exit);
/* --- Parse command line options --- */
atexit(fw_exit);
/* --- Parse command line options --- */