summaryrefslogtreecommitdiffstats
path: root/usr.bin/doas/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/doas/parse.y')
-rw-r--r--usr.bin/doas/parse.y8
1 files changed, 6 insertions, 2 deletions
diff --git a/usr.bin/doas/parse.y b/usr.bin/doas/parse.y
index 7e68cb7c5b3..900f7970b05 100644
--- a/usr.bin/doas/parse.y
+++ b/usr.bin/doas/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.19 2016/06/27 15:41:17 tedu Exp $ */
+/* $OpenBSD: parse.y,v 1.20 2016/09/02 18:12:30 tedu Exp $ */
/*
* Copyright (c) 2015 Ted Unangst <tedu@openbsd.org>
*
@@ -57,7 +57,7 @@ int yyparse(void);
%}
%token TPERMIT TDENY TAS TCMD TARGS
-%token TNOPASS TKEEPENV TSETENV
+%token TNOPASS TPERSIST TKEEPENV TSETENV
%token TSTRING
%%
@@ -119,6 +119,9 @@ options: /* none */ {
option: TNOPASS {
$$.options = NOPASS;
$$.envlist = NULL;
+ } | TPERSIST {
+ $$.options = PERSIST;
+ $$.envlist = NULL;
} | TKEEPENV {
$$.options = KEEPENV;
$$.envlist = NULL;
@@ -208,6 +211,7 @@ struct keyword {
{ "cmd", TCMD },
{ "args", TARGS },
{ "nopass", TNOPASS },
+ { "persist", TPERSIST },
{ "keepenv", TKEEPENV },
{ "setenv", TSETENV },
};