summaryrefslogtreecommitdiff
path: root/sql-common/client_plugin.c
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2011-01-20 12:59:47 +0100
committerSergei Golubchik <sergii@pisem.net>2011-01-20 12:59:47 +0100
commit785517dfe633c76221ea741d8c2280f8a62dd299 (patch)
tree800168a5bcb21d5a9dc1fb43ae344fde9e2e638e /sql-common/client_plugin.c
parent603444bc13a0ddc3f98318c78da394908e06025c (diff)
downloadmariadb-git-785517dfe633c76221ea741d8c2280f8a62dd299.tar.gz
lp:700982 - Non-portable code in client plugin (fails on ARM).
don't pass NULL as an argument where va_list is expected.
Diffstat (limited to 'sql-common/client_plugin.c')
-rw-r--r--sql-common/client_plugin.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sql-common/client_plugin.c b/sql-common/client_plugin.c
index c609f165d1c..9b28bff7937 100644
--- a/sql-common/client_plugin.c
+++ b/sql-common/client_plugin.c
@@ -239,6 +239,8 @@ int mysql_client_plugin_init()
{
MYSQL mysql;
struct st_mysql_client_plugin **builtin;
+ va_list unused;
+ LINT_INIT_STRUCT(unused);
if (initialized)
return 0;
@@ -255,7 +257,7 @@ int mysql_client_plugin_init()
pthread_mutex_lock(&LOCK_load_client_plugin);
for (builtin= mysql_client_builtins; *builtin; builtin++)
- add_plugin(&mysql, *builtin, 0, 0, 0);
+ add_plugin(&mysql, *builtin, 0, 0, unused);
pthread_mutex_unlock(&LOCK_load_client_plugin);
@@ -301,6 +303,9 @@ struct st_mysql_client_plugin *
mysql_client_register_plugin(MYSQL *mysql,
struct st_mysql_client_plugin *plugin)
{
+ va_list unused;
+ LINT_INIT_STRUCT(unused);
+
if (is_not_initialized(mysql, plugin->name))
return NULL;
@@ -315,7 +320,7 @@ mysql_client_register_plugin(MYSQL *mysql,
plugin= NULL;
}
else
- plugin= add_plugin(mysql, plugin, 0, 0, 0);
+ plugin= add_plugin(mysql, plugin, 0, 0, unused);
pthread_mutex_unlock(&LOCK_load_client_plugin);
return plugin;