diff options
author | 2012-09-03 21:28:21 +0000 | |
---|---|---|
committer | 2012-09-03 21:28:21 +0000 | |
commit | b0ff7ae98e93068dd67a094ab5813ebf3406f7c8 (patch) | |
tree | e3af756efb813be44885f1b6951ddc99c0a1e3aa | |
parent | - resolve unchecked malloc()'s; prompted by rustyBSD. (diff) | |
download | wireguard-openbsd-b0ff7ae98e93068dd67a094ab5813ebf3406f7c8.tar.xz wireguard-openbsd-b0ff7ae98e93068dd67a094ab5813ebf3406f7c8.zip |
fix the example filter to match current API by using
enum filter_status return value instead of plain int
ok todd@ gilles@
-rw-r--r-- | usr.sbin/smtpd/smtpfilter.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/usr.sbin/smtpd/smtpfilter.c b/usr.sbin/smtpd/smtpfilter.c index 9d2ddedb302..01c81a997e6 100644 --- a/usr.sbin/smtpd/smtpfilter.c +++ b/usr.sbin/smtpd/smtpfilter.c @@ -1,4 +1,4 @@ -/* $OpenBSD: smtpfilter.c,v 1.4 2012/08/20 18:15:37 gilles Exp $ */ +/* $OpenBSD: smtpfilter.c,v 1.5 2012/09/03 21:28:21 chl Exp $ */ /* * Copyright (c) 2011 Gilles Chehade <gilles@openbsd.org> @@ -61,21 +61,21 @@ enum filter_status dataline_cb(uint64_t, struct filter_dataline *, void *); enum filter_status helo_cb(uint64_t id, struct filter_helo *helo, void *mystuff) { - return 1; + return STATUS_IGNORE; } enum filter_status mail_cb(uint64_t id, struct filter_mail *mail, void *mystuff) { - return 1; + return STATUS_IGNORE; } enum filter_status rcpt_cb(uint64_t id, struct filter_rcpt *rcpt, void *mystuff) { if (rcpt->user[0] == 'a') - return 0; - return 1; + return STATUS_REJECT; + return STATUS_IGNORE; } |