diff options
author | mjl <mjl@pkgsrc.org> | 2002-11-30 14:56:53 +0000 |
---|---|---|
committer | mjl <mjl@pkgsrc.org> | 2002-11-30 14:56:53 +0000 |
commit | d06d8cf7ea5e9a76f67274531e84c9e4e5f91c87 (patch) | |
tree | ba65eddaff80be9cf5bb87661f69901c1bdc8b82 /security | |
parent | 4b4686acf867bdb4d21a753e30c929f755141e3c (diff) | |
download | pkgsrc-d06d8cf7ea5e9a76f67274531e84c9e4e5f91c87.tar.gz |
Add patch to reopen stdout/stderr to /dev/null to quelch whining about
closed descriptors in syslog.
Diffstat (limited to 'security')
-rw-r--r-- | security/smtpd/Makefile | 3 | ||||
-rw-r--r-- | security/smtpd/distinfo | 3 | ||||
-rw-r--r-- | security/smtpd/patches/patch-ab | 39 |
3 files changed, 43 insertions, 2 deletions
diff --git a/security/smtpd/Makefile b/security/smtpd/Makefile index 633efcadcaf..4fb9ff1ca97 100644 --- a/security/smtpd/Makefile +++ b/security/smtpd/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.6 2001/04/27 13:52:18 abs Exp $ +# $NetBSD: Makefile,v 1.7 2002/11/30 14:56:53 mjl Exp $ # DISTNAME= smtpd-2.0 +PKGREVISION=1 CATEGORIES= mail security MASTER_SITES= ftp://ftp.obtuse.com/pub/smtpd/ diff --git a/security/smtpd/distinfo b/security/smtpd/distinfo index b92de06e7d3..b62856c4aed 100644 --- a/security/smtpd/distinfo +++ b/security/smtpd/distinfo @@ -1,7 +1,8 @@ -$NetBSD: distinfo,v 1.2 2001/04/19 15:40:39 agc Exp $ +$NetBSD: distinfo,v 1.3 2002/11/30 14:56:53 mjl Exp $ SHA1 (smtpd-2.0.tar.gz) = 7c619e01a1e7b1baa23435159ba67894d5550188 Size (smtpd-2.0.tar.gz) = 62605 bytes SHA1 (patch-smtpd-2.0-RBL.gz) = 180bfcca83cb5e0523cf5d983083ed83bacdde7f Size (patch-smtpd-2.0-RBL.gz) = 3829 bytes SHA1 (patch-aa) = 2600fe1a486697c5a92a35fa14724b06b02555f5 +SHA1 (patch-ab) = 717ffbe58c771967ef2ce6a1ea56003535929ccf diff --git a/security/smtpd/patches/patch-ab b/security/smtpd/patches/patch-ab new file mode 100644 index 00000000000..cd267911d1b --- /dev/null +++ b/security/smtpd/patches/patch-ab @@ -0,0 +1,39 @@ +$NetBSD: patch-ab,v 1.1 2002/11/30 14:56:53 mjl Exp $ + +--- smtpfwdd.c.orig Sat Nov 30 15:41:10 2002 ++++ smtpfwdd.c Sat Nov 30 15:49:33 2002 +@@ -636,6 +636,18 @@ + exit(EX_OSERR); + } + ++ /* Reopen stderr and stdout to /dev/null to quelch whining */ ++ ++ if(open("/dev/null", O_WRONLY | O_APPEND) != 1) { ++ syslog(LOG_ERR, "Couldn't open /dev/null as stdout (%m)"); ++ exit(EX_OSERR); ++ } ++ ++ if(dup(1) != 2) { ++ syslog(LOG_ERR, "Couldn't dup /dev/null as stderr (%m)"); ++ exit(EX_OSERR); ++ } ++ + fclose(f); + closelog(); + if (lseek(0, body, SEEK_SET) < 0) { +@@ -760,7 +772,7 @@ + * The brains of this operation + */ + +-void ++int + main(int argc, char **argv) + { + int opt; +@@ -1129,4 +1141,6 @@ + sleep(poll_time); + } + } ++ ++return 0; + } |