2
0
mirror of https://gitlab.com/apparmor/apparmor synced 2025-08-29 13:28:19 +00:00

Simple rename to reflect the ( ) are not always used by flags (in the future)

Signed-off-by: John Johansen <john.johansen@canonical.com>
Acked-by: Kees Cook <kees@ubuntu.com>
This commit is contained in:
John Johansen 2012-01-02 16:48:34 -08:00
parent 49142c74a5
commit 37e2975d4d
2 changed files with 12 additions and 12 deletions

View File

@ -196,8 +196,8 @@ BOOL_VARIABLE $(\{{VARIABLE_NAME}\}|{VARIABLE_NAME})
PATHNAME (\/|{SET_VARIABLE}{POST_VAR_ID}){ID}* PATHNAME (\/|{SET_VARIABLE}{POST_VAR_ID}){ID}*
QPATHNAME \"(\/|{SET_VAR_PREFIX})([^\0"]|\\\")*\" QPATHNAME \"(\/|{SET_VAR_PREFIX})([^\0"]|\\\")*\"
FLAGOPEN_PAREN \( OPEN_PAREN \(
FLAGCLOSE_PAREN \) CLOSE_PAREN \)
FLAGSEP \, FLAGSEP \,
EQUALS = EQUALS =
ADD_ASSIGN \+= ADD_ASSIGN \+=
@ -322,16 +322,16 @@ LT_EQUAL <=
} }
<FLAGS_MODE>{ <FLAGS_MODE>{
{FLAGOPEN_PAREN} { {OPEN_PAREN} {
DUMP_PREPROCESS; DUMP_PREPROCESS;
PDEBUG("FLag (\n"); PDEBUG("FLag (\n");
return TOK_FLAG_OPENPAREN; return TOK_OPENPAREN;
} }
{FLAGCLOSE_PAREN} { {CLOSE_PAREN} {
DUMP_PREPROCESS; DUMP_PREPROCESS;
PDEBUG("Flag )\n"); PDEBUG("Flag )\n");
yy_pop_state(); yy_pop_state();
return TOK_FLAG_CLOSEPAREN; return TOK_CLOSEPAREN;
} }
{WS}+ { DUMP_PREPROCESS; /* Eat whitespace */ } {WS}+ { DUMP_PREPROCESS; /* Eat whitespace */ }
@ -601,11 +601,11 @@ LT_EQUAL <=
return TOK_COLON; return TOK_COLON;
} }
{FLAGOPEN_PAREN} { {OPEN_PAREN} {
DUMP_PREPROCESS; DUMP_PREPROCESS;
PDEBUG("FLag (\n"); PDEBUG("FLag (\n");
yy_push_state(FLAGS_MODE); yy_push_state(FLAGS_MODE);
return TOK_FLAG_OPENPAREN; return TOK_OPENPAREN;
} }
{VARIABLE_NAME} { {VARIABLE_NAME} {

View File

@ -110,6 +110,8 @@ void add_local_entry(struct codomain *cod);
%token TOK_SET %token TOK_SET
%token TOK_ALIAS %token TOK_ALIAS
%token TOK_PTRACE %token TOK_PTRACE
%token TOK_OPENPAREN
%token TOK_CLOSEPAREN
/* rlimits */ /* rlimits */
%token TOK_RLIMIT %token TOK_RLIMIT
@ -136,8 +138,6 @@ void add_local_entry(struct codomain *cod);
/* debug flag values */ /* debug flag values */
%token TOK_FLAGS %token TOK_FLAGS
%token TOK_FLAG_OPENPAREN
%token TOK_FLAG_CLOSEPAREN
%token TOK_FLAG_SEP %token TOK_FLAG_SEP
%token TOK_FLAG_ID %token TOK_FLAG_ID
@ -397,12 +397,12 @@ flags: { /* nothing */
$$ = fv; $$ = fv;
}; };
flags: TOK_FLAGS TOK_EQUALS TOK_FLAG_OPENPAREN flagvals TOK_FLAG_CLOSEPAREN flags: TOK_FLAGS TOK_EQUALS TOK_OPENPAREN flagvals TOK_CLOSEPAREN
{ {
$$ = $4; $$ = $4;
}; };
flags: TOK_FLAG_OPENPAREN flagvals TOK_FLAG_CLOSEPAREN flags: TOK_OPENPAREN flagvals TOK_CLOSEPAREN
{ {
$$ = $2; $$ = $2;
} }