summaryrefslogtreecommitdiff
path: root/mysys
diff options
context:
space:
mode:
Diffstat (limited to 'mysys')
-rw-r--r--mysys/mf_keycache.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mysys/mf_keycache.c b/mysys/mf_keycache.c
index 127bfff4af2..8f3e4767393 100644
--- a/mysys/mf_keycache.c
+++ b/mysys/mf_keycache.c
@@ -701,7 +701,7 @@ int prepare_resize_simple_key_cache(SIMPLE_KEY_CACHE_CB *keycache,
keycache->in_resize= 1;
/* Need to flush only if keycache is enabled. */
- if (keycache->can_be_used)
+ if (keycache->can_be_used && keycache->disk_blocks != -1)
{
/* Start the flush phase. */
keycache->resize_in_flush= 1;