summaryrefslogtreecommitdiff
path: root/sql/sql_cache.cc
diff options
context:
space:
mode:
authorDavi Arnaut <davi.arnaut@oracle.com>2010-07-23 22:36:21 -0300
committerDavi Arnaut <davi.arnaut@oracle.com>2010-07-23 22:36:21 -0300
commitbba8d5ca9b3bcb4fd9685e8af6bae6de0c9b7be7 (patch)
tree1b0b99de278ce9cb5a458afc12e6cc2280a885b6 /sql/sql_cache.cc
parent936217aac915f068deeef03544287411ddddba94 (diff)
parent32372a756f95c26f762c8a80ccfeaebb8d59e269 (diff)
downloadmariadb-git-bba8d5ca9b3bcb4fd9685e8af6bae6de0c9b7be7.tar.gz
Merge of mysql-5.1-bugteam into mysql-trunk-merge.
Diffstat (limited to 'sql/sql_cache.cc')
-rw-r--r--sql/sql_cache.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sql_cache.cc b/sql/sql_cache.cc
index b73de320ef5..d6dc9edc502 100644
--- a/sql/sql_cache.cc
+++ b/sql/sql_cache.cc
@@ -1673,7 +1673,8 @@ def_week_frmt: %lu, in_trans: %d, autocommit: %d",
thd->limit_found_rows = query->found_rows();
thd->status_var.last_query_cost= 0.0;
- thd->stmt_da->disable_status();
+ if (!thd->stmt_da->is_set())
+ thd->stmt_da->disable_status();
BLOCK_UNLOCK_RD(query_block);
MYSQL_QUERY_CACHE_HIT(thd->query(), (ulong) thd->limit_found_rows);