1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

MDEV-4472 Audit-plugin. Server-related part of the task.

file_logger became the service.
     Data like query_id now are sent to the audit plugin.
     Fix for MDEV-4770 ported from 10.0.
     Fix added for the read_maria_plugin_info().
     Log rotation can be disabled with 'set rotations=0'.
This commit is contained in:
Alexey Botchkov
2013-09-09 16:56:35 +05:00
parent 1e24cdc85b
commit 92265da9d7
21 changed files with 168 additions and 31 deletions

View File

@ -702,6 +702,8 @@ static my_bool read_maria_plugin_info(struct st_plugin_dl *plugin_dl,
sym= cur;
plugin_dl->allocated= true;
}
else
sym= ptr;
}
plugin_dl->plugins= (struct st_maria_plugin *)sym;
@ -2661,13 +2663,18 @@ static void update_func_longlong(THD *thd, struct st_mysql_sys_var *var,
static void update_func_str(THD *thd, struct st_mysql_sys_var *var,
void *tgt, const void *save)
{
char *old= *(char **) tgt;
*(char **)tgt= *(char **) save;
char *value= *(char**) save;
if (var->flags & PLUGIN_VAR_MEMALLOC)
{
*(char **)tgt= my_strdup(*(char **) save, MYF(0));
char *old= *(char**) tgt;
if (value)
*(char**) tgt= my_strdup(value, MYF(0));
else
*(char**) tgt= 0;
my_free(old);
}
else
*(char**) tgt= value;
}
static void update_func_double(THD *thd, struct st_mysql_sys_var *var,