Activity log for bug #700982

Date Who What changed Old value New value Message
2011-01-10 11:24:20 Kristian Nielsen bug added bug
2011-01-10 11:24:53 Kristian Nielsen maria: importance Undecided High
2011-01-10 11:24:53 Kristian Nielsen maria: status New Confirmed
2011-01-10 11:24:53 Kristian Nielsen maria: milestone 5.2
2011-01-10 11:34:19 Kristian Nielsen description The sql-common/client_plugin.c has this code: static struct st_mysql_client_plugin * add_plugin(MYSQL *mysql, struct st_mysql_client_plugin *plugin, void *dlhandle, int argc, va_list args) { ... } int mysql_client_plugin_init() { ... add_plugin(&mysql, *builtin, 0, 0, 0); struct st_mysql_client_plugin * mysql_client_register_plugin(MYSQL *mysql, struct st_mysql_client_plugin *plugin) { ... plugin= add_plugin(mysql, plugin, 0, 0, 0); This passes 0 for the va_list argument. This is not correct C, there is no guarantee that va_list is a pointer (or other type compatible with integer). I got a report that GCC 4.4 fails on this on ARM. An easy solution is to just declare and pass a dummy va_list instead; as argc is zero it won't be used anyway. [There is no code example in the source tree that actually uses the va_list arg in the init function. The only client plugin I could find is, in plugin/auth/dialog.c, and doesn't use the va_list argument: static int init_dialog() { ... } mysql_declare_client_plugin(AUTHENTICATION) "dialog", ... init_dialog, This BTW seems to be putting an int (*)() for init_dialog, where it should be int (*)(char *, size_t, int, va_list). This also isn't correct C, and while perhaps unlikely to fail in practice, there is no reason not to use the correct type for the function.] The sql-common/client_plugin.c has this code: static struct st_mysql_client_plugin * add_plugin(MYSQL *mysql, struct st_mysql_client_plugin *plugin, void *dlhandle,            int argc, va_list args) { ... } int mysql_client_plugin_init() {   ...     add_plugin(&mysql, *builtin, 0, 0, 0); struct st_mysql_client_plugin * mysql_client_register_plugin(MYSQL *mysql,                              struct st_mysql_client_plugin *plugin) {   ...     plugin= add_plugin(mysql, plugin, 0, 0, 0); This passes 0 for the va_list argument. This is not correct C, there is no guarantee that va_list is a pointer (or other type compatible with integer). I got a report that GCC 4.5 fails on this on ARM. An easy solution is to just declare and pass a dummy va_list instead; as argc is zero it won't be used anyway. [There is no code example in the source tree that actually uses the va_list arg in the init function. The only client plugin I could find is, in plugin/auth/dialog.c, and doesn't use the va_list argument: static int init_dialog() {   ... } mysql_declare_client_plugin(AUTHENTICATION)   "dialog",   ...   init_dialog, This BTW seems to be putting an int (*)() for init_dialog, where it should be int (*)(char *, size_t, int, va_list). This also isn't correct C, and while perhaps unlikely to fail in practice, there is no reason not to use the correct type for the function.]
2011-01-10 11:54:40 Sergei Golubchik maria: assignee Sergei (sergii)
2011-01-10 17:19:58 Emil Renner Berthing bug added subscriber Esmil
2011-01-12 11:38:31 Launchpad Janitor branch linked lp:~maria-captains/maria/5.2-serg
2011-03-12 16:12:41 Sergei Golubchik maria: status Confirmed Fix Committed
2011-10-28 08:59:06 Sergei Golubchik maria: status Fix Committed Fix Released
2011-11-22 18:54:02 Clint Byrum bug task added mysql-5.5 (Ubuntu)
2011-11-22 19:12:02 Clint Byrum bug watch added http://bugs.mysql.com/bug.php?id=62769
2011-11-22 19:12:02 Clint Byrum bug task added mysql-server
2011-11-22 19:21:28 Clint Byrum mysql-5.5 (Ubuntu): status New In Progress
2011-11-22 19:21:32 Clint Byrum mysql-5.5 (Ubuntu): assignee Clint Byrum (clint-fewbar)
2011-11-22 20:15:57 Clint Byrum mysql-5.5 (Ubuntu): importance Undecided High
2011-11-22 21:40:11 Launchpad Janitor mysql-5.5 (Ubuntu): status In Progress Fix Released
2011-11-22 22:12:22 Launchpad Janitor branch linked lp:ubuntu/mysql-5.5
2012-04-30 07:43:20 Launchpad Janitor branch linked lp:debian/experimental/mysql-5.5
2012-05-21 02:29:23 Laurynas Biveinis bug task added percona-server
2012-05-21 02:29:45 Laurynas Biveinis nominated for series percona-server/5.5
2012-05-21 02:29:45 Laurynas Biveinis bug task added percona-server/5.5
2012-05-21 02:29:59 Laurynas Biveinis percona-server/5.5: status New Confirmed
2012-06-15 07:42:08 Stewart Smith percona-server/5.5: importance Undecided Low
2012-06-15 07:42:10 Stewart Smith percona-server/5.5: status Confirmed Triaged
2013-02-17 21:33:05 Roel Van de Paar bug added subscriber RoelV
2014-02-14 10:59:46 Laurynas Biveinis nominated for series percona-server/5.6
2014-02-14 10:59:46 Laurynas Biveinis bug task added percona-server/5.6
2014-02-14 11:02:07 Laurynas Biveinis percona-server/5.6: milestone 5.6.13-60.5
2014-02-14 11:02:17 Laurynas Biveinis percona-server/5.6: status Triaged Fix Released
2014-02-14 11:24:07 Laurynas Biveinis tags upstream