From 46152464aa27954659a028d625f82acc601b7bbe Mon Sep 17 00:00:00 2001 From: unknown <stewart@willster.(none)> Date: Mon, 16 Oct 2006 17:41:29 +1000 Subject: [PATCH] BUG#19914 SELECT COUNT(*) sometimes returns MAX_INT on cluster tables update federated for fix sql/ha_federated.cc: update federated for ::info returning int sql/ha_federated.h: update federated for ::info returning int --- sql/ha_federated.cc | 6 +++--- sql/ha_federated.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index 7919519cdc..8be1e40f42 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -2385,7 +2385,7 @@ int ha_federated::rnd_pos(byte *buf, byte *pos) */ -void ha_federated::info(uint flag) +int ha_federated::info(uint flag) { char error_buffer[FEDERATED_QUERY_BUFFER_SIZE]; char status_buf[FEDERATED_QUERY_BUFFER_SIZE]; @@ -2463,7 +2463,7 @@ void ha_federated::info(uint flag) if (result) mysql_free_result(result); - DBUG_VOID_RETURN; + DBUG_RETURN(0); error: if (result) @@ -2472,7 +2472,7 @@ error: my_sprintf(error_buffer, (error_buffer, ": %d : %s", mysql_errno(mysql), mysql_error(mysql))); my_error(error_code, MYF(0), error_buffer); - DBUG_VOID_RETURN; + DBUG_RETURN(error_code); } diff --git a/sql/ha_federated.h b/sql/ha_federated.h index 61f5af686a..11e5a4f634 100644 --- a/sql/ha_federated.h +++ b/sql/ha_federated.h @@ -285,7 +285,7 @@ public: int rnd_next(byte *buf); //required int rnd_pos(byte *buf, byte *pos); //required void position(const byte *record); //required - void info(uint); //required + int info(uint); //required void update_auto_increment(void); int repair(THD* thd, HA_CHECK_OPT* check_opt); -- 2.30.9