diff options
author | abs <abs@pkgsrc.org> | 2004-11-01 17:25:25 +0000 |
---|---|---|
committer | abs <abs@pkgsrc.org> | 2004-11-01 17:25:25 +0000 |
commit | 982bd253df6c662562a6fe08a15d5d7f5630c083 (patch) | |
tree | 5da43423aac657600bb94f3f732ea6e523f835ea /mail/exim/patches | |
parent | 40ad5f21d0aee97bcd41b45ab7d9fb35df2b3ee9 (diff) | |
download | pkgsrc-982bd253df6c662562a6fe08a15d5d7f5630c083.tar.gz |
Update exim to 4.43nb1
Update exim-exiscan to 4.43_28nb1
Add back patch to ensure fork() is not called with closed fd 0, 1, or 2
Diffstat (limited to 'mail/exim/patches')
-rw-r--r-- | mail/exim/patches/patch-ag | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/mail/exim/patches/patch-ag b/mail/exim/patches/patch-ag new file mode 100644 index 00000000000..c561c6f8c97 --- /dev/null +++ b/mail/exim/patches/patch-ag @@ -0,0 +1,31 @@ +$NetBSD: patch-ag,v 1.3 2004/11/01 17:25:25 abs Exp $ + +--- src/daemon.c.orig Wed May 5 11:08:35 2004 ++++ src/daemon.c +@@ -756,6 +756,7 @@ daemon_go(void) + { + int *listen_sockets = NULL; + int listen_socket_count = 0; ++int fd; + ip_address_item *addresses = NULL; + + /* If any debugging options are set, turn on the D_pid bit so that all +@@ -1082,9 +1083,17 @@ if (background_daemon) + { + log_close_all(); /* Just in case anything was logged earlier */ + search_tidyup(); /* Just in case any were used in reading the config. */ +- close(0); /* Get rid of stdin/stdout/stderr */ ++ /* Get rid of stdin/stdout/stderr ++ close(0); + close(1); + close(2); ++ */ ++ /* Instead of closing, dup them to /dev/null */ ++ fd= open( "/dev/null", O_RDWR ); ++ dup2( fd, 0 ); ++ dup2( fd, 1 ); ++ dup2( fd, 2 ); ++ if( fd > 2 ) close( fd ); + log_stderr = NULL; /* So no attempt to copy paniclog output */ + + /* If the parent process of this one has pid == 1, we are re-initializing the |