summaryrefslogtreecommitdiff
path: root/sql/sql_plugin.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-06-13 20:19:11 +0200
committerSergei Golubchik <sergii@pisem.net>2013-06-13 20:19:11 +0200
commit1fb33e4a67918009e015967a41da6dbd65760ffa (patch)
treefb7d2599c5f87e472ec89caee42e151bb7847288 /sql/sql_plugin.cc
parent36c753519865ca9615e834a4f3e5cdf270cef230 (diff)
downloadmariadb-git-1fb33e4a67918009e015967a41da6dbd65760ffa.tar.gz
MDEV-4529 Assertion `tmp->state == 4' fails on mix of INSTALL SONAME / UNINSTALL PLUGIN
fix incorrect assert
Diffstat (limited to 'sql/sql_plugin.cc')
-rw-r--r--sql/sql_plugin.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/sql/sql_plugin.cc b/sql/sql_plugin.cc
index 55047a6da61..40ccd275947 100644
--- a/sql/sql_plugin.cc
+++ b/sql/sql_plugin.cc
@@ -2032,9 +2032,13 @@ static bool finalize_install(THD *thd, TABLE *table, const LEX_STRING *name)
ER_CANT_INITIALIZE_UDF, ER(ER_CANT_INITIALIZE_UDF),
name->str, "Plugin is disabled");
}
+ else if (tmp->state != PLUGIN_IS_UNINITIALIZED)
+ {
+ /* already installed */
+ return 0;
+ }
else
{
- DBUG_ASSERT(tmp->state == PLUGIN_IS_UNINITIALIZED);
if (plugin_initialize(tmp))
{
report_error(REPORT_TO_USER, ER_CANT_INITIALIZE_UDF, name->str,