1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-07 00:04:31 +03:00

MDEV-23894 UBSAN: several call to function show_binlog_vars(THD*, st_mysql_show_var*, char*) through pointer to incorrect function type 'int (*)(THD *, st_mysql_show_var *, void *, system_status_var *, enum_var_type) errors

This commit is contained in:
Eugene Kosov
2020-10-06 13:50:26 +03:00
parent 33f19876a2
commit 350c9eb705
4 changed files with 11 additions and 10 deletions

View File

@@ -8337,8 +8337,8 @@ show_ssl_get_server_not_after(THD *thd, SHOW_VAR *var, char *buff,
#endif /* HAVE_OPENSSL && !EMBEDDED_LIBRARY */
static int show_default_keycache(THD *thd, SHOW_VAR *var, char *buff,
enum enum_var_type scope)
static int show_default_keycache(THD *thd, SHOW_VAR *var, void *buff,
system_status_var *, enum_var_type)
{
struct st_data {
KEY_CACHE_STATISTICS stats;
@@ -8371,7 +8371,7 @@ static int show_default_keycache(THD *thd, SHOW_VAR *var, char *buff,
v->name= 0;
DBUG_ASSERT((char*)(v+1) <= buff + SHOW_VAR_FUNC_BUFF_SIZE);
DBUG_ASSERT((char*)(v+1) <= static_cast<char*>(buff) + SHOW_VAR_FUNC_BUFF_SIZE);
#undef set_one_keycache_var
@@ -8395,8 +8395,8 @@ static int show_memory_used(THD *thd, SHOW_VAR *var, char *buff,
#ifndef DBUG_OFF
static int debug_status_func(THD *thd, SHOW_VAR *var, char *buff,
enum enum_var_type scope)
static int debug_status_func(THD *thd, SHOW_VAR *var, void *buff,
system_status_var *, enum_var_type)
{
#define add_var(X,Y,Z) \
v->name= X; \