diff options
author | Jacek Masiulaniec <jacekm@cvs.openbsd.org> | 2009-02-15 13:44:07 +0000 |
---|---|---|
committer | Jacek Masiulaniec <jacekm@cvs.openbsd.org> | 2009-02-15 13:44:07 +0000 |
commit | f46db08589f99c87fb79d076751af70cd6b62366 (patch) | |
tree | a47791b88430a8746524659566773c923aa4f114 /usr.sbin | |
parent | 143eb6aa41b932670c7118cdab86ac9025f5c5c0 (diff) |
kill local vars that are used only once; ok gilles@
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/smtpd/queue_shared.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/usr.sbin/smtpd/queue_shared.c b/usr.sbin/smtpd/queue_shared.c index 42d0cff4109..53f6a74bb36 100644 --- a/usr.sbin/smtpd/queue_shared.c +++ b/usr.sbin/smtpd/queue_shared.c @@ -1,4 +1,4 @@ -/* $OpenBSD: queue_shared.c,v 1.7 2009/02/14 00:00:47 jacekm Exp $ */ +/* $OpenBSD: queue_shared.c,v 1.8 2009/02/15 13:44:06 jacekm Exp $ */ /* * Copyright (c) 2008 Gilles Chehade <gilles@openbsd.org> @@ -217,13 +217,12 @@ int queue_open_layout_messagefile(char *queuepath, struct message *messagep) { char pathname[MAXPATHLEN]; - mode_t mode = O_CREAT|O_EXCL|O_RDWR; if (! bsnprintf(pathname, MAXPATHLEN, "%s/%s/message", queuepath, messagep->message_id)) fatal("queue_open_incoming_message_file: snprintf"); - return open(pathname, mode, 0600); + return open(pathname, O_CREAT|O_EXCL|O_RDWR, 0600); } int @@ -304,7 +303,6 @@ queue_open_message_file(char *msgid) { int fd; char pathname[MAXPATHLEN]; - mode_t mode = O_RDONLY; u_int16_t hval; hval = queue_hash(msgid); @@ -313,7 +311,7 @@ queue_open_message_file(char *msgid) hval, msgid)) fatal("queue_open_message_file: snprintf"); - if ((fd = open(pathname, mode)) == -1) + if ((fd = open(pathname, O_RDONLY)) == -1) fatal("queue_open_message_file: open"); return fd; |