From 2f2d0b60d4ce3402dc27b76eadbf5e7d3aa89c12 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 27 Oct 2005 15:15:01 +0300 Subject: Fixes during review of pushed code Added back missing return in mysql_delete() mysql-test/my_manage.c: Cleanup: Remove some #ifdef mysql-test/r/drop_temp_table.result: Delete database that may be left from other test mysql-test/t/drop_temp_table.test: Delete database that may be left from other test sql/log.cc: false -> FALSE true -> TRUE Wait until readers_count is 0 (not just for a signal) NOTE: it's very likely that the way to handle readers_count is wrong. (We are in pthread_cond_wait freeing a mutex that is not the innermost mutex, which can lead to deadlocks) I will talk with Guilhem about this ASAP sql/log_event.h: Remove number from last even to help future merges (all compilers I know of can handle this properly) sql/sql_delete.cc: Add back missing RETURN (was lost in a merge) Indentation fixes --- sql/sql_delete.cc | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'sql/sql_delete.cc') diff --git a/sql/sql_delete.cc b/sql/sql_delete.cc index 83f50ba3ac5..c8e0b6c66f9 100644 --- a/sql/sql_delete.cc +++ b/sql/sql_delete.cc @@ -158,14 +158,16 @@ bool mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds, table->sort.io_cache= (IO_CACHE *) my_malloc(sizeof(IO_CACHE), MYF(MY_FAE | MY_ZEROFILL)); - if ( !(sortorder=make_unireg_sortorder((ORDER*) order->first, &length)) || + if (!(sortorder= make_unireg_sortorder((ORDER*) order->first, + &length)) || (table->sort.found_records = filesort(thd, table, sortorder, length, - select, HA_POS_ERROR, - &examined_rows)) + select, HA_POS_ERROR, + &examined_rows)) == HA_POS_ERROR) { delete select; free_underlaid_joins(thd, &thd->lex->select_lex); + DBUG_RETURN(TRUE); } /* Filesort has already found and selected the rows we want to delete, -- cgit v1.2.1