From 2f5b6053ca01b030f82da52e299f8231cdce12c5 Mon Sep 17 00:00:00 2001 From: unknown <tulin/mysqldev@mysql.com/production.mysql.com> Date: Wed, 17 Jan 2007 10:41:52 +0100 Subject: [PATCH] ha_ndbcluster.cc: Bug #25668 - corrected patch after test failures sql/ha_ndbcluster.cc: Bug #25668 - corrected patch after test failures --- sql/ha_ndbcluster.cc | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc index c40404f0219..f0ae4bae3a2 100644 --- a/sql/ha_ndbcluster.cc +++ b/sql/ha_ndbcluster.cc @@ -6109,7 +6109,23 @@ ndb_get_table_statistics(ha_ndbcluster* file, bool report_error, Ndb* ndb, DBUG_RETURN(0); retry: + if(report_error) + { + if (file && pTrans) + { + reterr= file->ndb_err(pTrans); + } + else + { + const NdbError& tmp= error; + ERR_PRINT(tmp); + reterr= ndb_to_mysql_error(&tmp); + } + } + else + reterr= error.code; + if (pTrans) { ndb->closeTransaction(pTrans); pTrans= NULL; @@ -6119,15 +6135,6 @@ ndb_get_table_statistics(ha_ndbcluster* file, bool report_error, Ndb* ndb, my_sleep(retry_sleep); continue; } - if(report_error) - { - const NdbError& tmp= error; - ERR_PRINT(tmp); - reterr= ndb_to_mysql_error(&tmp); - } - else - reterr= error.code; - break; } while(1); DBUG_PRINT("exit", ("failed, reterr: %u, NdbError %u(%s)", reterr, -- 2.30.9