On Tue, Dec 27, 2011 at 07:01:49PM -0800, John Johansen wrote:
> Change how we handle the parsing of the hat and profile keywords this allows
> us to get rid of the SUB_NAME2 start condition because the the whitespace
> that is allowed by these rules are now consumed by matching the keyword
> 
> Signed-off-by: John Johansen <[email protected]>
> ---
>  parser/parser_lex.l  |   39 +++++++++------------------------------
>  parser/parser_misc.c |    1 -
>  2 files changed, 9 insertions(+), 31 deletions(-)
> 
> diff --git a/parser/parser_lex.l b/parser/parser_lex.l
> index 5cb24fb..64b6a2e 100644
> --- a/parser/parser_lex.l
> +++ b/parser/parser_lex.l
> @@ -186,7 +186,8 @@ IP                {NUMBER}\.{NUMBER}\.{NUMBER}\.{NUMBER}
>  ALLOWED_QUOTED_ID    [^\0"]|\\\"
>  QUOTED_ID    \"{ALLOWED_QUOTED_ID}*\"
>  
> -HAT          hat[ \t]+
> +HAT          hat{WS}*
> +PROFILE              profile{WS}*

Should these match {WS}+ to ensure there's a trailing space separator?

>  KEYWORD         [[:alpha:]_]+
>  VARIABLE_NAME        [[:alpha:]][[:alnum:]_]*
>  SET_VAR_PREFIX  @

-- 
Steve Beattie
<[email protected]>
http://NxNW.org/~steve/

Attachment: signature.asc
Description: Digital signature

-- 
AppArmor mailing list
[email protected]
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/apparmor

Reply via email to