summaryrefslogtreecommitdiff
path: root/sql/sql_cache.cc
diff options
context:
space:
mode:
authorDavi Arnaut <Davi.Arnaut@Sun.COM>2009-01-22 09:22:26 -0200
committerDavi Arnaut <Davi.Arnaut@Sun.COM>2009-01-22 09:22:26 -0200
commitb88ec2f1a2e6e36bb6506ece9bfc9546d28eb1f8 (patch)
treed963cae6e8e386289ad1e7e15e7f258014bd699f /sql/sql_cache.cc
parentabbc922b650753a73c59a0c56c3c6074047b34f2 (diff)
parent6a834d1f4f8d41ef664c38f41408911080afebef (diff)
downloadmariadb-git-b88ec2f1a2e6e36bb6506ece9bfc9546d28eb1f8.tar.gz
Merge test case of Bug#40264 to mysql-5.1-bugteam
Diffstat (limited to 'sql/sql_cache.cc')
-rw-r--r--sql/sql_cache.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/sql_cache.cc b/sql/sql_cache.cc
index 5e098edbd7f..7c97ee4cf32 100644
--- a/sql/sql_cache.cc
+++ b/sql/sql_cache.cc
@@ -781,6 +781,9 @@ void query_cache_end_of_result(THD *thd)
if (thd->net.query_cache_query == 0)
DBUG_VOID_RETURN;
+ /* Ensure that only complete results are cached. */
+ DBUG_ASSERT(thd->main_da.is_eof());
+
if (thd->killed)
{
query_cache_abort(&thd->net);