]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib: event filters - Fix matching source location filename
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Tue, 23 May 2023 09:48:09 +0000 (12:48 +0300)
committerTimo Sirainen <timo.sirainen@open-xchange.com>
Mon, 20 Nov 2023 12:22:31 +0000 (14:22 +0200)
The comparisons always used the created event's source filename rather than
e.g. event_want_debug() function's source filename.

src/lib/event-filter.c

index 151f763444f8afd515d18d54c7d4817745a6b77f..7eac8778ad9db53c8b33a353e510bf13d6a38592 100644 (file)
@@ -901,7 +901,7 @@ event_filter_query_match_cmp(struct event_filter_node *node,
                        return !((source_linenum != node->field.value.intmax &&
                                  node->field.value.intmax != 0) ||
                                 source_filename == NULL ||
-                                strcmp(event->source_filename, node->field.value.str) != 0);
+                                strcmp(source_filename, node->field.value.str) != 0);
                case EVENT_FILTER_NODE_TYPE_EVENT_CATEGORY:
                        return event_has_category(event, node, log_type);
                case EVENT_FILTER_NODE_TYPE_EVENT_FIELD_EXACT: