From ac88d25b331f043fdc1480359f47febec2516f5b Mon Sep 17 00:00:00 2001 From: heikki Date: Tue, 8 Aug 2006 11:38:34 +0000 Subject: [PATCH] Remove redundant check_trx_exists() and ut_a() from r701, as suggested by Marko --- handler/ha_innodb.cc | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/handler/ha_innodb.cc b/handler/ha_innodb.cc index 963a94af240..5867de36cb6 100644 --- a/handler/ha_innodb.cc +++ b/handler/ha_innodb.cc @@ -5023,18 +5023,12 @@ ha_innobase::delete_all_rows(void) } /* Get the transaction associated with the current thd, or create one - if not yet created */ + if not yet created, and update prebuilt->trx */ - trx = check_trx_exists(thd); - - /* Update prebuilt->trx */ update_thd(current_thd); /* Truncate the table in InnoDB */ - ut_a(prebuilt->trx == - (trx_t*) current_thd->ha_data[innobase_hton.slot]); - error = row_truncate_table_for_mysql(prebuilt->table, trx); if (error == DB_ERROR) { /* Cannot truncate; resort to ha_innobase::delete_row() */