Fix binlogfilter matching
The matching always checked the default database when it should only check it if there are no tables in the statement.
This commit is contained in:
parent
06c01439fb
commit
738ae9178b
@ -405,10 +405,11 @@ static bool should_skip_query(const BinlogConfig& config, const std::string& sql
|
||||
qc_free_table_names(names, n);
|
||||
}
|
||||
|
||||
// Also check for the default database in case the query has no tables in it
|
||||
if (!rval && should_skip(config, db))
|
||||
// Also check for the default database in case the query has no tables in it. The dot at the end is
|
||||
// required to distinct database names from table names.
|
||||
if (n == 0)
|
||||
{
|
||||
rval = true;
|
||||
rval = should_skip(config, db + '.');
|
||||
}
|
||||
|
||||
gwbuf_free(buf);
|
||||
|
Loading…
x
Reference in New Issue
Block a user