diff --git a/ngxtop/config_parser.py b/ngxtop/config_parser.py index 0d9f00a..e84a07c 100644 --- a/ngxtop/config_parser.py +++ b/ngxtop/config_parser.py @@ -133,7 +133,7 @@ def build_pattern(log_format): elif log_format == 'common': log_format = LOG_FORMAT_COMMON pattern = re.sub(REGEX_SPECIAL_CHARS, r'\\\1', log_format) - pattern = re.sub(REGEX_LOG_FORMAT_VARIABLE, '(?P<\\1>.*)', pattern) + pattern = re.sub(REGEX_LOG_FORMAT_VARIABLE, '(?P<\\1>.*?)', pattern) return re.compile(pattern)