diff --git a/storage/spider/mysql-test/spider/bugfix/r/mdev_30727.result b/storage/spider/mysql-test/spider/bugfix/r/mdev_30727.result index ce8ebdc3966..79a383feb83 100644 --- a/storage/spider/mysql-test/spider/bugfix/r/mdev_30727.result +++ b/storage/spider/mysql-test/spider/bugfix/r/mdev_30727.result @@ -1,12 +1,12 @@ CREATE FUNCTION spider_direct_sql RETURNS INT SONAME 'ha_spider.so'; SELECT spider_direct_sql ('SELECT * FROM s','a','srv "b"'); -ERROR HY000: Plugin 'SPIDER' is not loaded +ERROR HY000: Can't initialize function 'spider_direct_sql'; Plugin 'SPIDER' is not loaded CREATE FUNCTION spider_bg_direct_sql RETURNS INT SONAME 'ha_spider.so'; SELECT spider_bg_direct_sql ('SELECT * FROM s','a','srv "b"'); -ERROR HY000: Plugin 'SPIDER' is not loaded +ERROR HY000: Can't initialize function 'spider_bg_direct_sql'; Plugin 'SPIDER' is not loaded CREATE FUNCTION spider_copy_tables RETURNS INT SONAME 'ha_spider.so'; SELECT spider_copy_tables ('t', '0', '0'); -ERROR HY000: Plugin 'SPIDER' is not loaded +ERROR HY000: Can't initialize function 'spider_copy_tables'; Plugin 'SPIDER' is not loaded CREATE FUNCTION spider_flush_table_mon_cache RETURNS INT SONAME 'ha_spider.so'; SELECT spider_flush_table_mon_cache (); spider_flush_table_mon_cache () diff --git a/storage/spider/mysql-test/spider/bugfix/t/mdev_30727.test b/storage/spider/mysql-test/spider/bugfix/t/mdev_30727.test index e1d917e7147..ebd08edce24 100644 --- a/storage/spider/mysql-test/spider/bugfix/t/mdev_30727.test +++ b/storage/spider/mysql-test/spider/bugfix/t/mdev_30727.test @@ -1,13 +1,13 @@ CREATE FUNCTION spider_direct_sql RETURNS INT SONAME 'ha_spider.so'; ---error ER_PLUGIN_IS_NOT_LOADED +--error ER_CANT_INITIALIZE_UDF SELECT spider_direct_sql ('SELECT * FROM s','a','srv "b"'); CREATE FUNCTION spider_bg_direct_sql RETURNS INT SONAME 'ha_spider.so'; ---error ER_PLUGIN_IS_NOT_LOADED +--error ER_CANT_INITIALIZE_UDF SELECT spider_bg_direct_sql ('SELECT * FROM s','a','srv "b"'); CREATE FUNCTION spider_copy_tables RETURNS INT SONAME 'ha_spider.so'; ---error ER_PLUGIN_IS_NOT_LOADED +--error ER_CANT_INITIALIZE_UDF SELECT spider_copy_tables ('t', '0', '0'); # spider_flush_table_mon_cache does not require spider init to function diff --git a/storage/spider/spd_copy_tables.cc b/storage/spider/spd_copy_tables.cc index 1783fe7374b..524ad7dd9e9 100644 --- a/storage/spider/spd_copy_tables.cc +++ b/storage/spider/spd_copy_tables.cc @@ -1154,9 +1154,6 @@ error: DBUG_RETURN(0); } -#undef my_error -extern "C" void my_error(unsigned int nr, unsigned long MyFlags, ...); - my_bool spider_copy_tables_init_body( UDF_INIT *initid, UDF_ARGS *args, @@ -1165,7 +1162,7 @@ my_bool spider_copy_tables_init_body( DBUG_ENTER("spider_copy_tables_init_body"); if (!spider_hton_ptr) { - my_error(ER_PLUGIN_IS_NOT_LOADED, MYF(0), "SPIDER"); + strcpy(message, "Plugin 'SPIDER' is not loaded"); goto error; } if (args->arg_count != 3 && args->arg_count != 4) diff --git a/storage/spider/spd_direct_sql.cc b/storage/spider/spd_direct_sql.cc index 4f6bc0a4405..524e8b7443a 100644 --- a/storage/spider/spd_direct_sql.cc +++ b/storage/spider/spd_direct_sql.cc @@ -1789,9 +1789,6 @@ error: DBUG_RETURN(0); } -#undef my_error -extern "C" void my_error(unsigned int nr, unsigned long MyFlags, ...); - my_bool spider_direct_sql_init_body( UDF_INIT *initid, UDF_ARGS *args, @@ -1802,7 +1799,7 @@ my_bool spider_direct_sql_init_body( DBUG_ENTER("spider_direct_sql_init_body"); if (!spider_hton_ptr) { - my_error(ER_PLUGIN_IS_NOT_LOADED, MYF(0), "SPIDER"); + strcpy(message, "Plugin 'SPIDER' is not loaded"); goto error; } if (args->arg_count != 3)