summaryrefslogtreecommitdiff
path: root/mysql-test/r/query_cache.result
diff options
context:
space:
mode:
authorunknown <thek@adventure.(none)>2008-03-06 12:40:46 +0100
committerunknown <thek@adventure.(none)>2008-03-06 12:40:46 +0100
commitc184cd6320ac3b5cbd1ab953d94ea1ef8c4d200e (patch)
tree3b2a7d0e54b92544d472a9375dbd425a93a95eac /mysql-test/r/query_cache.result
parenta89ba0c68031aa3a962ef4244e027dd9481a65c1 (diff)
downloadmariadb-git-c184cd6320ac3b5cbd1ab953d94ea1ef8c4d200e.tar.gz
Bug#25132 disabled query cache: Qcache_free_blocks = 1
The initial value of free memory blocks in 0. When the query cache is enabled a new memory block gets allocated and is assigned number 1. The free memory block is later split each time query cache memory is allocated for new blocks. This means that the free memory block counter won't be reduced to zero when the number of allocated blocks are zero, but rather one. To avoid confusion this patch changes this behavior so that the free memory block counter is reset to zero when the query cache is disabled. Note that when the query cache is enabled and resized the free memory block counter was still calculated correctly. mysql-test/r/query_cache.result: test case mysql-test/t/query_cache.test: test case sql/sql_cache.cc: Restore the memory block count to 0 for consistency.
Diffstat (limited to 'mysql-test/r/query_cache.result')
-rw-r--r--mysql-test/r/query_cache.result10
1 files changed, 10 insertions, 0 deletions
diff --git a/mysql-test/r/query_cache.result b/mysql-test/r/query_cache.result
index 68f18d1b0b2..b47c91b0406 100644
--- a/mysql-test/r/query_cache.result
+++ b/mysql-test/r/query_cache.result
@@ -1650,6 +1650,16 @@ Variable_name Value
Qcache_queries_in_cache 1
DROP DATABASE bug30269;
DROP USER 'bug30269'@'localhost';
+#
+# Bug#25132 disabled query cache: Qcache_free_blocks = 1
+#
+set global query_cache_size=100000;
+set global query_cache_size=0;
+set global query_cache_type=0;
+show status like 'Qcache_free_blocks';
+Variable_name Value
+Qcache_free_blocks 0
+Restore default values.
set GLOBAL query_cache_type=default;
set GLOBAL query_cache_limit=default;
set GLOBAL query_cache_min_res_unit=default;