summaryrefslogtreecommitdiffstats
path: root/usr.bin/mail/temp.c
diff options
context:
space:
mode:
authorcharnier <charnier@FreeBSD.org>1997-07-24 06:56:33 +0000
committercharnier <charnier@FreeBSD.org>1997-07-24 06:56:33 +0000
commit2df2878db2fff5ba7f8f8fe84159b8f955530617 (patch)
tree5ac950789af8a285aa2da6004e09394a8c86e761 /usr.bin/mail/temp.c
parenta27c19ecbf0d42e6bb692c5111ebc7888cb7b1aa (diff)
downloadFreeBSD-src-2df2878db2fff5ba7f8f8fe84159b8f955530617.zip
FreeBSD-src-2df2878db2fff5ba7f8f8fe84159b8f955530617.tar.gz
Use err(3).
Diffstat (limited to 'usr.bin/mail/temp.c')
-rw-r--r--usr.bin/mail/temp.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/usr.bin/mail/temp.c b/usr.bin/mail/temp.c
index 0690027..37f6026 100644
--- a/usr.bin/mail/temp.c
+++ b/usr.bin/mail/temp.c
@@ -32,11 +32,15 @@
*/
#ifndef lint
+#if 0
static char sccsid[] = "@(#)temp.c 8.1 (Berkeley) 6/6/93";
+#endif
+static const char rcsid[] =
+ "$Id$";
#endif /* not lint */
#include "rcv.h"
-#include <errno.h>
+#include <err.h>
#include "extern.h"
/*
@@ -62,10 +66,8 @@ tinit()
tmpdir = _PATH_TMP;
else {
len = strlen(tmpdir);
- if ((cp = malloc(len + 2)) == NULL) {
- (void)fprintf(stderr, "mail: %s\n", strerror(errno));
- exit (1);
- }
+ if ((cp = malloc(len + 2)) == NULL)
+ err(1, NULL);
(void)strcpy(cp, tmpdir);
cp[len] = '/';
cp[len + 1] = '\0';
OpenPOWER on IntegriCloud