From eb60c7af29eaaefeb68516339df2c7f86136ce23 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=A9r=C3=A9mie=20Galarneau?= Date: Mon, 11 Nov 2019 18:53:56 -0500 Subject: [PATCH] Fix: overly restrictive datetime regexp rejects valid dates MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit The patch introducting backward_compat_group_by_session() was edited (by me) before being merged and the regular expression was made stricter. However, one of the changes was erroneous and restricted the range of the second digit of the 'month' field to [0-1]. Change it back to [0-9] to accept all months from 1-12. Signed-off-by: Jérémie Galarneau --- src/bin/lttng-relayd/backward-compatibility-group-by.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/lttng-relayd/backward-compatibility-group-by.c b/src/bin/lttng-relayd/backward-compatibility-group-by.c index 0127f63f5..dd5ccffd5 100644 --- a/src/bin/lttng-relayd/backward-compatibility-group-by.c +++ b/src/bin/lttng-relayd/backward-compatibility-group-by.c @@ -29,7 +29,7 @@ #define DATETIME_STRING_SIZE 16 #define DATETIME_REGEX \ - ".*-[1-2][0-9][0-9][0-9][0-1][0-1][0-3][0-9]-[0-2][0-9][0-5][0-9][0-5][0-9]$" + ".*-[1-2][0-9][0-9][0-9][0-1][0-9][0-3][0-9]-[0-2][0-9][0-5][0-9][0-5][0-9]$" /* * Provide support for --group-output-by-session for producer >= 2.4 and < 2.11. -- 2.34.1