MDEV-9225 mysql_upgrade segfault due to missing /etc/my.cnf.d
In case of missing includedir file, we would attempt to free a NULL pointer. Make sure to guard against that.
This commit is contained in:
parent
b7dc830274
commit
2a47817896
@ -182,7 +182,8 @@ static const char *load_default_groups[]=
|
|||||||
static void free_used_memory(void)
|
static void free_used_memory(void)
|
||||||
{
|
{
|
||||||
/* Free memory allocated by 'load_defaults' */
|
/* Free memory allocated by 'load_defaults' */
|
||||||
free_defaults(defaults_argv);
|
if (defaults_argv)
|
||||||
|
free_defaults(defaults_argv);
|
||||||
|
|
||||||
dynstr_free(&ds_args);
|
dynstr_free(&ds_args);
|
||||||
dynstr_free(&conn_args);
|
dynstr_free(&conn_args);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user