You've already forked mariadb-connector-c
mirror of
https://github.com/mariadb-corporation/mariadb-connector-c.git
synced 2025-08-08 14:02:17 +03:00
Merge branch '3.1' into 3.2
This commit is contained in:
@@ -330,6 +330,7 @@ struct st_mysql_client_plugin * STDCALL
|
|||||||
mysql_client_register_plugin(MYSQL *mysql,
|
mysql_client_register_plugin(MYSQL *mysql,
|
||||||
struct st_mysql_client_plugin *plugin)
|
struct st_mysql_client_plugin *plugin)
|
||||||
{
|
{
|
||||||
|
struct st_mysql_client_plugin *found_plugin= NULL;
|
||||||
va_list unused;
|
va_list unused;
|
||||||
LINT_INIT_STRUCT(unused);
|
LINT_INIT_STRUCT(unused);
|
||||||
|
|
||||||
@@ -339,18 +340,11 @@ mysql_client_register_plugin(MYSQL *mysql,
|
|||||||
pthread_mutex_lock(&LOCK_load_client_plugin);
|
pthread_mutex_lock(&LOCK_load_client_plugin);
|
||||||
|
|
||||||
/* make sure the plugin wasn't loaded meanwhile */
|
/* make sure the plugin wasn't loaded meanwhile */
|
||||||
if (find_plugin(plugin->name, plugin->type))
|
if (!(found_plugin= find_plugin(plugin->name, plugin->type)))
|
||||||
{
|
found_plugin= add_plugin(mysql, plugin, 0, 0, unused);
|
||||||
my_set_error(mysql, CR_AUTH_PLUGIN_CANNOT_LOAD,
|
|
||||||
SQLSTATE_UNKNOWN, ER(CR_AUTH_PLUGIN_CANNOT_LOAD),
|
|
||||||
plugin->name, "it is already loaded");
|
|
||||||
plugin= NULL;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
plugin= add_plugin(mysql, plugin, 0, 0, unused);
|
|
||||||
|
|
||||||
pthread_mutex_unlock(&LOCK_load_client_plugin);
|
pthread_mutex_unlock(&LOCK_load_client_plugin);
|
||||||
return plugin;
|
return found_plugin;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -4174,7 +4174,7 @@ my_bool mariadb_get_infov(MYSQL *mysql, enum mariadb_value value, void *arg, ...
|
|||||||
*((char **)arg)= (char *)ma_pvio_tls_cipher(mysql->net.pvio->ctls);
|
*((char **)arg)= (char *)ma_pvio_tls_cipher(mysql->net.pvio->ctls);
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
goto error;
|
*((char **)arg)= NULL;
|
||||||
break;
|
break;
|
||||||
case MARIADB_CLIENT_ERRORS:
|
case MARIADB_CLIENT_ERRORS:
|
||||||
*((char ***)arg)= (char **)client_errors;
|
*((char ***)arg)= (char **)client_errors;
|
||||||
|
Reference in New Issue
Block a user