]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
cdr_adaptive_odbc: Prevent filter warnings
authorNaveen Albert <asterisk@phreaknet.org>
Mon, 28 Jun 2021 13:48:16 +0000 (13:48 +0000)
committerN A <mail@interlinked.x10host.com>
Wed, 4 Aug 2021 12:59:46 +0000 (07:59 -0500)
Previously, if CDR filters were used so that
not all CDR records used all sections defined
in cdr_adaptive_odbc.conf, then warnings will
always be emitted (if each CDR record is unique
to a particular section, n-1 warnings to be
specific).

This turns the offending warning log into
a verbose message like the other one, since
this behavior is intentional and not
indicative of anything wrong.

ASTERISK-29494

Change-Id: Ifd314fa9298722bc99494d5ca2658a5caa94a5f8

cdr/cdr_adaptive_odbc.c

index eed809a7ddee4ca90470aa80948560d797cd9b48..4a10ec8142366c336d1897c96b7f9129aefa4e35 100644 (file)
@@ -740,7 +740,7 @@ static int odbc_log(struct ast_cdr *cdr)
                        } else if (entry->filtervalue
                                && ((!entry->negatefiltervalue && entry->filtervalue[0] != '\0')
                                        || (entry->negatefiltervalue && entry->filtervalue[0] == '\0'))) {
-                               ast_log(AST_LOG_WARNING, "CDR column '%s' was not set and does not match filter of"
+                               ast_verb(4, "CDR column '%s' was not set and does not match filter of"
                                        " %s'%s'.  Cancelling this CDR.\n",
                                        entry->cdrname, entry->negatefiltervalue ? "!" : "",
                                        entry->filtervalue);