From: Guannan Ren Date: Sat, 9 Mar 2013 14:49:16 +0000 (+0800) Subject: util: escapes special characters in VIR_LOG_REGEX X-Git-Tag: v1.0.4-rc1~105 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eb086eb5b58c771cb3f731ef2169dab6a8967cff;p=thirdparty%2Flibvirt.git util: escapes special characters in VIR_LOG_REGEX In debug mode, the bug failed to start vm error: Failed to start domain rhel5u9 error: internal error Out of space while reading console log output: ... --- diff --git a/src/util/virlog.c b/src/util/virlog.c index 130bdff1c2..957d993a3b 100644 --- a/src/util/virlog.c +++ b/src/util/virlog.c @@ -80,7 +80,7 @@ static regex_t *virLogRegex = NULL; #define VIR_LOG_DATE_REGEX "[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]" -#define VIR_LOG_TIME_REGEX "[0-9][0-9]:[0-9][0-9]:[0-9][0-9].[0-9][0-9][0-9]+[0-9][0-9][0-9][0-9]" +#define VIR_LOG_TIME_REGEX "[0-9][0-9]:[0-9][0-9]:[0-9][0-9]\\.[0-9][0-9][0-9]\\+[0-9][0-9][0-9][0-9]" #define VIR_LOG_PID_REGEX "[0-9]+" #define VIR_LOG_LEVEL_REGEX "debug|info|warning|error"