Fix buffer size in cache rules
If a database, table and a column was defined, the null terminating character would be written past the end of the buffer.
This commit is contained in:
parent
4554bd1743
commit
ceb763c9be
2
server/modules/filter/cache/rules.cc
vendored
2
server/modules/filter/cache/rules.cc
vendored
@ -1176,7 +1176,7 @@ static bool cache_rule_matches_column_regexp(CACHE_RULE *self,
|
||||
table_len = default_table_len;
|
||||
}
|
||||
|
||||
char buffer[database_len + 1 + table_len + strlen(info->column) + 1];
|
||||
char buffer[database_len + 1 + table_len + 1 + strlen(info->column) + 1];
|
||||
buffer[0] = 0;
|
||||
|
||||
if (database)
|
||||
|
Loading…
x
Reference in New Issue
Block a user