From 954dc6f6948c84a718d2ae01a3abb95eb755a22a Mon Sep 17 00:00:00 2001 From: John Johansen Date: Fri, 24 Feb 2012 04:20:46 -0800 Subject: [PATCH] Fix hexdigit conversion in the pcre parser The pcre parser in the dfa backend is not correctly converting escaped hex string like \0x0d This is the minimal patch to fix, and we should investigate just using the C/C++ conversion routines here. I also I nominated for the 2.7 series. Signed-off-by: John Johansen Acked-by: Seth Arnold --- parser/libapparmor_re/parse.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/parser/libapparmor_re/parse.y b/parser/libapparmor_re/parse.y index e2f3a8169..d4d21591a 100644 --- a/parser/libapparmor_re/parse.y +++ b/parser/libapparmor_re/parse.y @@ -169,7 +169,7 @@ int hexdigit(char c) else if (c >= 'A' && c <= 'F') return 10 + c - 'A'; else if (c >= 'a' && c <= 'f') - return 10 + c - 'A'; + return 10 + c - 'a'; else return -1; }