mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-30 22:05:46 +00:00
make per-command defaults work with sudoedit
This commit is contained in:
16
toke.l
16
toke.l
@@ -333,14 +333,7 @@ MONITOR[[:blank:]]*: {
|
||||
BEGIN INITIAL;
|
||||
}
|
||||
|
||||
sudoedit {
|
||||
BEGIN GOTCMND;
|
||||
LEXTRACE("COMMAND ");
|
||||
if (!fill_cmnd(yytext, yyleng))
|
||||
yyterminate();
|
||||
} /* sudo -e */
|
||||
|
||||
<GOTDEFS>{PATH} {
|
||||
<GOTDEFS>({PATH}|sudoedit) {
|
||||
/* no command args allowed for Defaults!/path */
|
||||
if (!fill_cmnd(yytext, yyleng))
|
||||
yyterminate();
|
||||
@@ -348,6 +341,13 @@ sudoedit {
|
||||
return(COMMAND);
|
||||
}
|
||||
|
||||
sudoedit {
|
||||
BEGIN GOTCMND;
|
||||
LEXTRACE("COMMAND ");
|
||||
if (!fill_cmnd(yytext, yyleng))
|
||||
yyterminate();
|
||||
} /* sudo -e */
|
||||
|
||||
{PATH} {
|
||||
/* directories can't have args... */
|
||||
if (yytext[yyleng - 1] == '/') {
|
||||
|
Reference in New Issue
Block a user