[Commits] Rev 2904: - don't pass NULL where va_list is expected - fails on ARM. in http://bazaar.launchpad.net/~maria-captains/maria/5.2/

serg at askmonty.org serg at askmonty.org
Wed Jan 12 13:09:53 EET 2011


At http://bazaar.launchpad.net/~maria-captains/maria/5.2/

------------------------------------------------------------
revno: 2904
revision-id: sergii at pisem.net-20110112110843-m7bmiae96jx9w4q5
parent: sergii at pisem.net-20101231093914-7nhg8p4chmn272zr
fixes bug(s): https://launchpad.net/bugs/700982
committer: Sergei Golubchik <sergii at pisem.net>
branch nick: 5.2
timestamp: Wed 2011-01-12 12:08:43 +0100
message:
  - don't pass NULL where va_list is expected - fails on ARM.
  - fix function prototype to match
-------------- next part --------------
=== modified file 'plugin/auth/dialog.c'
--- a/plugin/auth/dialog.c	2010-04-08 13:58:04 +0000
+++ b/plugin/auth/dialog.c	2011-01-12 11:08:43 +0000
@@ -327,7 +327,10 @@ static int perform_dialog(MYSQL_PLUGIN_V
   or fall back to the default implementation.
 */
 
-static int init_dialog()
+static int init_dialog(char *errbuf __attribute__((unused)),
+                       size_t sizeof_errbuf __attribute__((unused)),
+                       int argc __attribute__((unused)),
+                       va_list args __attribute__((unused)))
 {
   void *sym= dlsym(RTLD_DEFAULT, "mysql_authentication_dialog_ask");
   ask= sym ? (mysql_authentication_dialog_ask_t)sym : builtin_ask;

=== modified file 'sql-common/client_plugin.c'
--- a/sql-common/client_plugin.c	2010-03-29 15:13:53 +0000
+++ b/sql-common/client_plugin.c	2011-01-12 11:08:43 +0000
@@ -239,6 +239,7 @@ int mysql_client_plugin_init()
 {
   MYSQL mysql;
   struct st_mysql_client_plugin **builtin;
+  va_list unused;
 
   if (initialized)
     return 0;
@@ -255,7 +256,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 +302,8 @@ struct st_mysql_client_plugin *
 mysql_client_register_plugin(MYSQL *mysql,
                              struct st_mysql_client_plugin *plugin)
 {
+  va_list unused;
+
   if (is_not_initialized(mysql, plugin->name))
     return NULL;
 
@@ -315,7 +318,7 @@ mysql_client_register_plugin(MYSQL *mysq
     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;



More information about the commits mailing list