mirror of
https://github.com/MariaDB/server.git
synced 2025-01-29 10:14:19 +01:00
Fix a buffer overflow in INFORMATION_SCHEMA.GLOBAL_VARIABLES, caused by MDEV-12179
pretty_print_engine_list(): When the plugin list is empty, return an empty string instead of allocating a buffer of 0 bytes and then trying to write a NUL byte into it.
This commit is contained in:
parent
4e1fa7f63d
commit
8a8cca2865
1 changed files with 1 additions and 1 deletions
|
@ -1483,7 +1483,7 @@ pretty_print_engine_list(THD *thd, plugin_ref *list)
|
|||
size_t size;
|
||||
char *buf, *pos;
|
||||
|
||||
if (!list)
|
||||
if (!list || !*list)
|
||||
return thd->strmake("", 0);
|
||||
|
||||
size= 0;
|
||||
|
|
Loading…
Add table
Reference in a new issue