summaryrefslogtreecommitdiff
path: root/storage/federated
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2012-01-16 20:16:35 +0100
committerSergei Golubchik <sergii@pisem.net>2012-01-16 20:16:35 +0100
commit38e3ae155db08ab2e9e5c267f05f89bec0542b33 (patch)
tree7289bbef1ba3f495aa5c7cdb7d0a3f993a5bbc80 /storage/federated
parentc56483d972d023105fbcb0f47af0042ee092657c (diff)
parented1ba992c1d3c3ecbe6a2769c51ceb5d27606d3b (diff)
downloadmariadb-git-38e3ae155db08ab2e9e5c267f05f89bec0542b33.tar.gz
mysql-5.5 merge
Diffstat (limited to 'storage/federated')
-rw-r--r--storage/federated/ha_federated.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/storage/federated/ha_federated.cc b/storage/federated/ha_federated.cc
index 1091d88ffc8..4294f4b094f 100644
--- a/storage/federated/ha_federated.cc
+++ b/storage/federated/ha_federated.cc
@@ -1686,6 +1686,16 @@ int ha_federated::close(void)
mysql_close(mysql);
mysql= NULL;
+ /*
+ mysql_close() might return an error if a remote server's gone
+ for some reason. If that happens while removing a table from
+ the table cache, the error will be propagated to a client even
+ if the original query was not issued against the FEDERATED table.
+ So, don't propagate errors from mysql_close().
+ */
+ if (table->in_use)
+ table->in_use->clear_error();
+
DBUG_RETURN(free_share(share));
}