diff options
Diffstat (limited to 'sql/sql_plugin.cc')
-rw-r--r-- | sql/sql_plugin.cc | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/sql/sql_plugin.cc b/sql/sql_plugin.cc index e2449613458..811b82ebe05 100644 --- a/sql/sql_plugin.cc +++ b/sql/sql_plugin.cc @@ -1446,10 +1446,7 @@ static bool plugin_load_list(MEM_ROOT *tmp_root, int *argc, char **argv, free_root(tmp_root, MYF(MY_MARK_BLOCKS_FREE)); if (plugin_add(tmp_root, &name, &dl, argc, argv, REPORT_TO_LOG)) - { - pthread_mutex_unlock(&LOCK_plugin); goto error; - } } plugin_dl_del(&dl); // reduce ref count } @@ -1459,10 +1456,7 @@ static bool plugin_load_list(MEM_ROOT *tmp_root, int *argc, char **argv, free_root(tmp_root, MYF(MY_MARK_BLOCKS_FREE)); pthread_mutex_lock(&LOCK_plugin); if (plugin_add(tmp_root, &name, &dl, argc, argv, REPORT_TO_LOG)) - { - pthread_mutex_unlock(&LOCK_plugin); goto error; - } } pthread_mutex_unlock(&LOCK_plugin); name.length= dl.length= 0; @@ -1485,6 +1479,7 @@ static bool plugin_load_list(MEM_ROOT *tmp_root, int *argc, char **argv, } DBUG_RETURN(FALSE); error: + pthread_mutex_unlock(&LOCK_plugin); sql_print_error("Couldn't load plugin named '%s' with soname '%s'.", name.str, dl.str); DBUG_RETURN(TRUE); |