summaryrefslogtreecommitdiff
path: root/usr.sbin/smtpd/parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/smtpd/parser.c')
-rw-r--r--usr.sbin/smtpd/parser.c20
1 files changed, 18 insertions, 2 deletions
diff --git a/usr.sbin/smtpd/parser.c b/usr.sbin/smtpd/parser.c
index 6ade78d00dd..291d2bc5272 100644
--- a/usr.sbin/smtpd/parser.c
+++ b/usr.sbin/smtpd/parser.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: parser.c,v 1.3 2008/12/27 16:45:01 jacekm Exp $ */
+/* $OpenBSD: parser.c,v 1.4 2009/01/04 19:37:41 gilles Exp $ */
/*
* Copyright (c) 2006 Pierre-Yves Ritschard <pyr@openbsd.org>
@@ -56,12 +56,16 @@ struct token {
static const struct token t_main[];
static const struct token t_show[];
+static const struct token t_pause[];
+static const struct token t_resume[];
static const struct token t_main[] = {
{KEYWORD, "show", NONE, t_show},
{KEYWORD, "monitor", MONITOR, NULL},
+ {KEYWORD, "pause", NONE, t_pause},
{KEYWORD, "reload", RELOAD, NULL},
- {KEYWORD, "stop", SHUTDOWN, NULL},
+ {KEYWORD, "resume", NONE, t_resume},
+ {KEYWORD, "stop", SHUTDOWN, NULL},
{ENDTOKEN, "", NONE, NULL}
};
@@ -71,6 +75,18 @@ static const struct token t_show[] = {
{ENDTOKEN, "", NONE, NULL}
};
+static const struct token t_pause[] = {
+ {KEYWORD, "local", PAUSE_MDA, NULL},
+ {KEYWORD, "outgoing", PAUSE_MTA, NULL},
+ {ENDTOKEN, "", NONE, NULL}
+};
+
+static const struct token t_resume[] = {
+ {KEYWORD, "local", RESUME_MDA, NULL},
+ {KEYWORD, "outgoing", RESUME_MTA, NULL},
+ {ENDTOKEN, "", NONE, NULL}
+};
+
static struct parse_result res;
struct parse_result *