From 52f038c5c3a065d2c68197535d844f6ed00a09cc Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Wed, 12 Feb 2014 21:17:28 +0100 Subject: [PATCH 1/8] MDEV-5655 Server crashes on NAME_CONST containing AND/OR expressions fix the NAME_CONST check to only allow literals, negated literals, and literals with the explicit collation. --- mysql-test/r/func_misc.result | 7 +++++++ mysql-test/t/func_misc.test | 10 ++++++++++ sql/item.cc | 31 +++++++++++++++++++++---------- 3 files changed, 38 insertions(+), 10 deletions(-) diff --git a/mysql-test/r/func_misc.result b/mysql-test/r/func_misc.result index 5910a45c839..56d27ff78be 100644 --- a/mysql-test/r/func_misc.result +++ b/mysql-test/r/func_misc.result @@ -265,3 +265,10 @@ SELECT '1' IN ('1', INET_NTOA(0)); '1' IN ('1', INET_NTOA(0)) 1 End of tests +SELECT NAME_CONST('a', -(1 OR 2)) OR 1; +ERROR HY000: Incorrect arguments to NAME_CONST +SELECT NAME_CONST('a', -(1 AND 2)) AND 1; +ERROR HY000: Incorrect arguments to NAME_CONST +SELECT NAME_CONST('a', -(1)) OR 1; +NAME_CONST('a', -(1)) OR 1 +1 diff --git a/mysql-test/t/func_misc.test b/mysql-test/t/func_misc.test index 2a72578aca7..c4cc7734186 100644 --- a/mysql-test/t/func_misc.test +++ b/mysql-test/t/func_misc.test @@ -300,3 +300,13 @@ SELECT '1' IN ('1', INET_NTOA(0)); --echo End of tests + +# +# MDEV-5655 Server crashes on NAME_CONST containing AND/OR expressions +# +--error ER_WRONG_ARGUMENTS +SELECT NAME_CONST('a', -(1 OR 2)) OR 1; +--error ER_WRONG_ARGUMENTS +SELECT NAME_CONST('a', -(1 AND 2)) AND 1; +SELECT NAME_CONST('a', -(1)) OR 1; + diff --git a/sql/item.cc b/sql/item.cc index 976449e6353..82b6c921ec7 100644 --- a/sql/item.cc +++ b/sql/item.cc @@ -1284,17 +1284,28 @@ bool Item_name_const::is_null() Item_name_const::Item_name_const(Item *name_arg, Item *val): value_item(val), name_item(name_arg) { - if (!(valid_args= name_item->basic_const_item() && - (value_item->basic_const_item() || - ((value_item->type() == FUNC_ITEM) && - ((((Item_func *) value_item)->functype() == - Item_func::COLLATE_FUNC) || - ((((Item_func *) value_item)->functype() == - Item_func::NEG_FUNC) && - (((Item_func *) value_item)->key_item()->type() != - FUNC_ITEM))))))) - my_error(ER_WRONG_ARGUMENTS, MYF(0), "NAME_CONST"); Item::maybe_null= TRUE; + valid_args= true; + if (!name_item->basic_const_item()) + goto err; + + if (value_item->basic_const_item()) + return; // ok + + if (value_item->type() == FUNC_ITEM) + { + Item_func *value_func= (Item_func *) value_item; + if (value_func->functype() != Item_func::COLLATE_FUNC && + value_func->functype() != Item_func::NEG_FUNC) + goto err; + + if (value_func->key_item()->basic_const_item()) + return; // ok + } + +err: + valid_args= false; + my_error(ER_WRONG_ARGUMENTS, MYF(0), "NAME_CONST"); } From 5f5d2db1415cb32f03b39224267b83ac721ff68c Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 13 Feb 2014 08:09:07 +0100 Subject: [PATCH 2/8] fix embedded tests (mainly by backporting 5.5. changes) mysql-test/suite/maria/t/distinct.test: Remove the test that requires SSL. One test case for a bug is enough. sql/scheduler.cc: make it the same as in 5.5 storage/innodb_plugin/row/row0mysql.c: make it the same as in 5.5 storage/innodb_plugin/row/row0sel.c: make it the same as in 5.5 storage/xtradb/row/row0mysql.c: make it the same as in 5.5 storage/xtradb/row/row0sel.c: make it the same as in 5.5 --- mysql-test/suite/maria/r/distinct.result | 8 -------- mysql-test/suite/maria/t/distinct.test | 4 ---- sql/scheduler.cc | 1 - storage/innodb_plugin/row/row0mysql.c | 4 ---- storage/innodb_plugin/row/row0sel.c | 1 - storage/xtradb/row/row0mysql.c | 4 ---- storage/xtradb/row/row0sel.c | 1 - 7 files changed, 23 deletions(-) diff --git a/mysql-test/suite/maria/r/distinct.result b/mysql-test/suite/maria/r/distinct.result index 04d5e3d6a2c..cceb6b82005 100644 --- a/mysql-test/suite/maria/r/distinct.result +++ b/mysql-test/suite/maria/r/distinct.result @@ -15,11 +15,3 @@ GROUP_CONCAT(a) 3 1 DROP TABLE t1; -CREATE TABLE t1 (a INT, b VARCHAR(1)) ENGINE=MyISAM; -INSERT INTO t1 VALUES (7,'q'),(2,NULL),(7,'g'),(6,'x'); -SELECT DISTINCT MAX( a ) FROM t1 GROUP BY b ORDER BY DES_DECRYPT( b ); -MAX( a ) -2 -7 -6 -DROP TABLE t1; diff --git a/mysql-test/suite/maria/t/distinct.test b/mysql-test/suite/maria/t/distinct.test index b30d97b8383..f326b5a691f 100644 --- a/mysql-test/suite/maria/t/distinct.test +++ b/mysql-test/suite/maria/t/distinct.test @@ -19,7 +19,3 @@ SELECT GROUP_CONCAT(a) FROM t1 GROUP BY b; SELECT DISTINCT GROUP_CONCAT(a) FROM t1 GROUP BY b; DROP TABLE t1; -CREATE TABLE t1 (a INT, b VARCHAR(1)) ENGINE=MyISAM; -INSERT INTO t1 VALUES (7,'q'),(2,NULL),(7,'g'),(6,'x'); -SELECT DISTINCT MAX( a ) FROM t1 GROUP BY b ORDER BY DES_DECRYPT( b ); -DROP TABLE t1; diff --git a/sql/scheduler.cc b/sql/scheduler.cc index 5b8f834aecc..cf60e461bb9 100644 --- a/sql/scheduler.cc +++ b/sql/scheduler.cc @@ -69,7 +69,6 @@ static bool no_threads_end(THD *thd, bool put_in_cache) void one_thread_scheduler(scheduler_functions *func) { func->max_threads= 1; - max_connections= 1; func->max_connections= &max_connections; func->connection_count= &connection_count; #ifndef EMBEDDED_LIBRARY diff --git a/storage/innodb_plugin/row/row0mysql.c b/storage/innodb_plugin/row/row0mysql.c index 9379912a218..fc934f3771e 100644 --- a/storage/innodb_plugin/row/row0mysql.c +++ b/storage/innodb_plugin/row/row0mysql.c @@ -1079,7 +1079,6 @@ row_insert_for_mysql( ins_node_t* node = prebuilt->ins_node; ut_ad(trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (prebuilt->table->ibd_file_missing) { ut_print_timestamp(stderr); @@ -1313,7 +1312,6 @@ row_update_for_mysql( trx_t* trx = prebuilt->trx; ut_ad(prebuilt && trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); UT_NOT_USED(mysql_rec); if (prebuilt->table->ibd_file_missing) { @@ -1483,7 +1481,6 @@ row_unlock_for_mysql( trx_t* trx = prebuilt->trx; ut_ad(prebuilt && trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (UNIV_UNLIKELY (!srv_locks_unsafe_for_binlog @@ -2724,7 +2721,6 @@ row_truncate_table_for_mysql( redo log records on the truncated tablespace, we will assign a new tablespace identifier to the truncated tablespace. */ - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); ut_ad(table); if (srv_created_new_raw) { diff --git a/storage/innodb_plugin/row/row0sel.c b/storage/innodb_plugin/row/row0sel.c index d825d799a3c..4b3fdfd6541 100644 --- a/storage/innodb_plugin/row/row0sel.c +++ b/storage/innodb_plugin/row/row0sel.c @@ -3434,7 +3434,6 @@ row_search_for_mysql( rec_offs_init(offsets_); ut_ad(index && pcur && search_tuple); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (UNIV_UNLIKELY(prebuilt->table->ibd_file_missing)) { ut_print_timestamp(stderr); diff --git a/storage/xtradb/row/row0mysql.c b/storage/xtradb/row/row0mysql.c index c56711cadc4..db8e61c3502 100644 --- a/storage/xtradb/row/row0mysql.c +++ b/storage/xtradb/row/row0mysql.c @@ -1084,7 +1084,6 @@ row_insert_for_mysql( ins_node_t* node = prebuilt->ins_node; ut_ad(trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (prebuilt->table->ibd_file_missing) { ut_print_timestamp(stderr); @@ -1326,7 +1325,6 @@ row_update_for_mysql( trx_t* trx = prebuilt->trx; ut_ad(prebuilt && trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); UT_NOT_USED(mysql_rec); if (prebuilt->table->ibd_file_missing) { @@ -1497,7 +1495,6 @@ row_unlock_for_mysql( trx_t* trx = prebuilt->trx; ut_ad(prebuilt && trx); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (UNIV_UNLIKELY (!srv_locks_unsafe_for_binlog @@ -2830,7 +2827,6 @@ row_truncate_table_for_mysql( redo log records on the truncated tablespace, we will assign a new tablespace identifier to the truncated tablespace. */ - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); ut_ad(table); if (srv_created_new_raw) { diff --git a/storage/xtradb/row/row0sel.c b/storage/xtradb/row/row0sel.c index ba3db5bc022..8aebb3e3cd4 100644 --- a/storage/xtradb/row/row0sel.c +++ b/storage/xtradb/row/row0sel.c @@ -3435,7 +3435,6 @@ row_search_for_mysql( rec_offs_init(offsets_); ut_ad(index && pcur && search_tuple); - ut_ad(trx->mysql_thread_id == os_thread_get_curr_id()); if (UNIV_UNLIKELY(prebuilt->table->ibd_file_missing)) { ut_print_timestamp(stderr); From 642495345f0b35e87db4e8e2f4cfd0b3df724019 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 13 Feb 2014 20:18:07 +0100 Subject: [PATCH 3/8] Remove the fix from MySQL-5.1 that's not necessary in 5.3 --- sql/item_subselect.cc | 9 +++------ sql/item_subselect.h | 1 - 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/sql/item_subselect.cc b/sql/item_subselect.cc index edb3f71583c..3e02598be12 100644 --- a/sql/item_subselect.cc +++ b/sql/item_subselect.cc @@ -2796,7 +2796,7 @@ subselect_single_select_engine(THD *thd_arg, st_select_lex *select, select_result_interceptor *result_arg, Item_subselect *item_arg) :subselect_engine(thd_arg, item_arg, result_arg), - prepared(0), executed(0), optimize_error(0), + prepared(0), executed(0), select_lex(select), join(0) { select_lex->master_unit()->item= item_arg; @@ -2810,7 +2810,7 @@ int subselect_single_select_engine::get_identifier() void subselect_single_select_engine::cleanup() { DBUG_ENTER("subselect_single_select_engine::cleanup"); - prepared= executed= optimize_error= 0; + prepared= executed= 0; join= 0; result->cleanup(); select_lex->uncacheable&= ~UNCACHEABLE_DEPENDENT_INJECTED; @@ -3039,9 +3039,6 @@ int subselect_single_select_engine::exec() { DBUG_ENTER("subselect_single_select_engine::exec"); - if (optimize_error) - DBUG_RETURN(1); - char const *save_where= thd->where; SELECT_LEX *save_select= thd->lex->current_select; thd->lex->current_select= select_lex; @@ -3054,7 +3051,7 @@ int subselect_single_select_engine::exec() if (join->optimize()) { thd->where= save_where; - executed= optimize_error= 1; + executed= 1; thd->lex->current_select= save_select; DBUG_RETURN(join->error ? join->error : 1); } diff --git a/sql/item_subselect.h b/sql/item_subselect.h index d75e415c347..bdd9ca023bf 100644 --- a/sql/item_subselect.h +++ b/sql/item_subselect.h @@ -764,7 +764,6 @@ class subselect_single_select_engine: public subselect_engine { bool prepared; /* simple subselect is prepared */ bool executed; /* simple subselect is executed */ - bool optimize_error; /* simple subselect optimization failed */ st_select_lex *select_lex; /* corresponding select_lex */ JOIN * join; /* corresponding JOIN structure */ public: From 4b57720caabb434c055bb67b6cf73e51cb044138 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 13 Feb 2014 20:20:17 +0100 Subject: [PATCH 4/8] use a different error for MySQL bug#11747970 - kill the query, as it was supposed to be in bug#11747970, don't fake an error. (this kill can be useful for other bugs too) --- mysql-test/r/error_simulation.result | 2 +- mysql-test/t/error_simulation.test | 2 +- sql/sql_select.cc | 8 +------- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/mysql-test/r/error_simulation.result b/mysql-test/r/error_simulation.result index 6d9ec36bb1d..049900b76c7 100644 --- a/mysql-test/r/error_simulation.result +++ b/mysql-test/r/error_simulation.result @@ -94,7 +94,7 @@ INSERT INTO t1 VALUES (1),(2); INSERT INTO t2 VALUES (1),(2); SET SESSION debug="+d,bug11747970_raise_error"; INSERT IGNORE INTO t2 SELECT f1 FROM t1 a WHERE NOT EXISTS (SELECT 1 FROM t2 b WHERE a.f1 = b.f1); -ERROR HY000: Unknown error +ERROR 70100: Query execution was interrupted SET SESSION debug = DEFAULT; DROP TABLE t1,t2; # diff --git a/mysql-test/t/error_simulation.test b/mysql-test/t/error_simulation.test index 5dcc1fa9dcf..1048bf85e44 100644 --- a/mysql-test/t/error_simulation.test +++ b/mysql-test/t/error_simulation.test @@ -103,7 +103,7 @@ CREATE TABLE t2(f1 INT); INSERT INTO t1 VALUES (1),(2); INSERT INTO t2 VALUES (1),(2); SET SESSION debug="+d,bug11747970_raise_error"; ---error 1105 +--error ER_QUERY_INTERRUPTED INSERT IGNORE INTO t2 SELECT f1 FROM t1 a WHERE NOT EXISTS (SELECT 1 FROM t2 b WHERE a.f1 = b.f1); SET SESSION debug = DEFAULT; DROP TABLE t1,t2; diff --git a/sql/sql_select.cc b/sql/sql_select.cc index 235383622cb..6f96a432a97 100644 --- a/sql/sql_select.cc +++ b/sql/sql_select.cc @@ -3154,13 +3154,7 @@ make_join_statistics(JOIN *join, List &tables_list, #endif DBUG_EXECUTE_IF("bug11747970_raise_error", - { - if (!error) - { - my_error(ER_UNKNOWN_ERROR, MYF(0)); - goto error; - } - }); + { join->thd->killed= KILL_QUERY_HARD; }); if (error) { table->file->print_error(error, MYF(0)); From 12253abadb1b2993469dbfad59b1043ecc974983 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Thu, 13 Feb 2014 20:21:57 +0100 Subject: [PATCH 5/8] MDEV-714 LP:1020645 - crash (sig 11) with union query Don't ignore the error from st_select_lex_unit::optimize() --- mysql-test/r/union_crash-714.result | 5 +++++ mysql-test/t/union_crash-714.test | 9 +++++++++ sql/sql_union.cc | 3 ++- 3 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 mysql-test/r/union_crash-714.result create mode 100644 mysql-test/t/union_crash-714.test diff --git a/mysql-test/r/union_crash-714.result b/mysql-test/r/union_crash-714.result new file mode 100644 index 00000000000..2811f8bd7f5 --- /dev/null +++ b/mysql-test/r/union_crash-714.result @@ -0,0 +1,5 @@ +create table t1 (i tinyint); +set debug='+d,bug11747970_raise_error'; +insert into t1 (i) select i from t1 union select i from t1; +ERROR 70100: Query execution was interrupted +drop table t1; diff --git a/mysql-test/t/union_crash-714.test b/mysql-test/t/union_crash-714.test new file mode 100644 index 00000000000..a1fb9c12ec1 --- /dev/null +++ b/mysql-test/t/union_crash-714.test @@ -0,0 +1,9 @@ +# +# MDEV-714 LP:1020645 - crash (sig 11) with union query +# +--source include/have_debug.inc +create table t1 (i tinyint); +set debug='+d,bug11747970_raise_error'; +--error ER_QUERY_INTERRUPTED +insert into t1 (i) select i from t1 union select i from t1; +drop table t1; diff --git a/sql/sql_union.cc b/sql/sql_union.cc index 5ca4af8eb0d..f9fecae38c4 100644 --- a/sql/sql_union.cc +++ b/sql/sql_union.cc @@ -629,7 +629,8 @@ bool st_select_lex_unit::exec() if (!(uncacheable & ~UNCACHEABLE_EXPLAIN) && item) item->make_const(); - saved_error= optimize(); + if ((saved_error= optimize())) + DBUG_RETURN(saved_error); if (uncacheable || !item || !item->assigned() || describe) { From 8a26d19088be2b821d820d89b97cc26c0fbeb65f Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Fri, 14 Feb 2014 10:39:25 +0100 Subject: [PATCH 6/8] record incorrect result for MDEV-5539 Empty results in UNION with Sphinx engine (just to have the test in the tree when we merge the upstream fix) --- mysql-test/suite/sphinx/union-5539.result | 10 ++++++++++ mysql-test/suite/sphinx/union-5539.test | 15 +++++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 mysql-test/suite/sphinx/union-5539.result create mode 100644 mysql-test/suite/sphinx/union-5539.test diff --git a/mysql-test/suite/sphinx/union-5539.result b/mysql-test/suite/sphinx/union-5539.result new file mode 100644 index 00000000000..7e0e7bb27ec --- /dev/null +++ b/mysql-test/suite/sphinx/union-5539.result @@ -0,0 +1,10 @@ +create table ts (id bigint unsigned not null, w int not null, query varchar(255) not null, index(query)) engine=sphinx connection="sphinx://127.0.0.1:16002/*"; +SELECT a.* FROM (SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500') AS a UNION SELECT b.* FROM (SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500') AS b; +id w query +SELECT a.* FROM (SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500') AS a UNION SELECT b.* FROM (SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500') AS b; +id w query +1 1 ;mode=extended2;limit=1000000;maxmatches=500 +2 1 ;mode=extended2;limit=1000000;maxmatches=500 +3 1 ;mode=extended2;limit=1000000;maxmatches=500 +4 1 ;mode=extended2;limit=1000000;maxmatches=500 +drop table ts; diff --git a/mysql-test/suite/sphinx/union-5539.test b/mysql-test/suite/sphinx/union-5539.test new file mode 100644 index 00000000000..61e70ba1c66 --- /dev/null +++ b/mysql-test/suite/sphinx/union-5539.test @@ -0,0 +1,15 @@ +# +# MDEV-5539 Empty results in UNION with Sphinx engine +# +eval create table ts (id bigint unsigned not null, w int not null, query varchar(255) not null, index(query)) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/*"; +let $q1=SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500'; +let $q2=SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500'; +######################## +# BUG BUG BUG !!! +# Note, the result below is incorrect! It should be updated when +# MDEV-5539 is fixed upstream!!! +######################## +eval SELECT a.* FROM ($q1) AS a UNION SELECT b.* FROM ($q2) AS b; +eval SELECT a.* FROM ($q2) AS a UNION SELECT b.* FROM ($q1) AS b; +drop table ts; + From 9d5731ef1b5a3f879d4234cddc694b629d823106 Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Fri, 14 Feb 2014 11:14:10 +0100 Subject: [PATCH 7/8] fix the test --- mysql-test/suite/sphinx/union-5539.result | 2 +- mysql-test/suite/sphinx/union-5539.test | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/mysql-test/suite/sphinx/union-5539.result b/mysql-test/suite/sphinx/union-5539.result index 7e0e7bb27ec..414bcce30e9 100644 --- a/mysql-test/suite/sphinx/union-5539.result +++ b/mysql-test/suite/sphinx/union-5539.result @@ -1,4 +1,4 @@ -create table ts (id bigint unsigned not null, w int not null, query varchar(255) not null, index(query)) engine=sphinx connection="sphinx://127.0.0.1:16002/*"; +create table ts (id bigint unsigned not null, w int not null, query varchar(255) not null, index(query)) engine=sphinx connection="sphinx://127.0.0.1:PORT/*"; SELECT a.* FROM (SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500') AS a UNION SELECT b.* FROM (SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500') AS b; id w query SELECT a.* FROM (SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500') AS a UNION SELECT b.* FROM (SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500') AS b; diff --git a/mysql-test/suite/sphinx/union-5539.test b/mysql-test/suite/sphinx/union-5539.test index 61e70ba1c66..ec73be1ab3e 100644 --- a/mysql-test/suite/sphinx/union-5539.test +++ b/mysql-test/suite/sphinx/union-5539.test @@ -1,6 +1,7 @@ # # MDEV-5539 Empty results in UNION with Sphinx engine # +--replace_result $SPHINXSEARCH_PORT PORT eval create table ts (id bigint unsigned not null, w int not null, query varchar(255) not null, index(query)) engine=sphinx connection="sphinx://127.0.0.1:$SPHINXSEARCH_PORT/*"; let $q1=SELECT * FROM ts si WHERE si.query=';mode=extended2;limit=1000000;maxmatches=500'; let $q2=SELECT * FROM ts si WHERE si.query='@* 123nothingtofind123;mode=extended2;limit=1000000;maxmatches=500'; From 5a21dc7df1024c13c212f687c5ebc40d9cb74c5b Mon Sep 17 00:00:00 2001 From: Sergei Golubchik Date: Fri, 14 Feb 2014 14:08:16 +0100 Subject: [PATCH 8/8] fix suite/sphinx/suite.pm to not start searchd twice --- mysql-test/suite/sphinx/suite.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/mysql-test/suite/sphinx/suite.pm b/mysql-test/suite/sphinx/suite.pm index e708b12faea..6a9d5f9ebc0 100644 --- a/mysql-test/suite/sphinx/suite.pm +++ b/mysql-test/suite/sphinx/suite.pm @@ -71,6 +71,7 @@ sub searchd_start { my ($sphinx, $test) = @_; # My::Config::Group, My::Test return unless $exe_sphinx_indexer and $exe_sphinx_searchd; + return if $sphinx->{proc}; # Already started # First we must run the indexer to create the data. my $sphinx_data_dir= "$::opt_vardir/" . $sphinx->name();