summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorJacek Masiulaniec <jacekm@cvs.openbsd.org>2008-12-21 13:06:44 +0000
committerJacek Masiulaniec <jacekm@cvs.openbsd.org>2008-12-21 13:06:44 +0000
commit3082e8e5b678e99cf90ab6aa92b2d7f7112b2fa7 (patch)
treeea3ffaa6afddf4e489fa3d299cd841e07e0038f7 /usr.sbin
parent2e2449b98ca52b5e8ba2e24a7e48d02467e0ec67 (diff)
Add more compile time checking; fix warnings reported by gcc.
From: Nicholas Marriott <nicholas.marriott@gmail.com>
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/smtpd/showqueue.c6
-rw-r--r--usr.sbin/smtpd/smtpctl/Makefile8
2 files changed, 9 insertions, 5 deletions
diff --git a/usr.sbin/smtpd/showqueue.c b/usr.sbin/smtpd/showqueue.c
index 4e7c8241947..2b46b8248ef 100644
--- a/usr.sbin/smtpd/showqueue.c
+++ b/usr.sbin/smtpd/showqueue.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: showqueue.c,v 1.1 2008/12/06 02:44:08 gilles Exp $ */
+/* $OpenBSD: showqueue.c,v 1.2 2008/12/21 13:06:41 jacekm Exp $ */
/*
* Copyright (c) 2008 Gilles Chehade <gilles@openbsd.org>
@@ -153,8 +153,6 @@ show_runqueue(int flags)
{
DIR *dirp;
struct dirent *dp;
- u_int16_t bucket;
- const char *errstr;
char pathname[MAXPATHLEN];
FILE *fp;
struct message envelope;
@@ -212,7 +210,7 @@ display_envelope(struct message *envelope, int flags)
printf("UNKNOWN");
}
- printf("|%s|%s@%s|%s@%s|%llu|%u\n",
+ printf("|%s|%s@%s|%s@%s|%d|%u\n",
envelope->message_uid,
envelope->sender.user, envelope->sender.domain,
envelope->recipient.user, envelope->recipient.domain,
diff --git a/usr.sbin/smtpd/smtpctl/Makefile b/usr.sbin/smtpd/smtpctl/Makefile
index 3c3acf8c1d8..bf7b10c2e7a 100644
--- a/usr.sbin/smtpd/smtpctl/Makefile
+++ b/usr.sbin/smtpd/smtpctl/Makefile
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile,v 1.2 2008/12/06 02:44:08 gilles Exp $
+# $OpenBSD: Makefile,v 1.3 2008/12/21 13:06:43 jacekm Exp $
.PATH: ${.CURDIR}/..
@@ -10,6 +10,12 @@ BINMODE?=555
BINDIR= /usr/bin
MAN= smtpctl.8
+CFLAGS+= -g3 -ggdb -I${.CURDIR}/..
+CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes
+CFLAGS+= -Wmissing-declarations
+CFLAGS+= -Wshadow -Wpointer-arith -Wcast-qual
+CFLAGS+= -Wsign-compare -Wbounded
+
SRCS= smtpctl.c parser.c buffer.c imsg.c log.c showqueue.c
LDFLAGS= -lutil
.include <bsd.prog.mk>