summaryrefslogtreecommitdiff
path: root/myisam/mi_extra.c
diff options
context:
space:
mode:
authorigor@rurik.mysql.com <>2003-08-02 02:43:18 -0700
committerigor@rurik.mysql.com <>2003-08-02 02:43:18 -0700
commit9306f55d8e62aca4e00dab3408a8395af85fb947 (patch)
treeadd5cbee3049a38799b03ee640b5ae06fbc34ef1 /myisam/mi_extra.c
parentf0ca5d545d801a5c1efdda878a5f85079c30f428 (diff)
downloadmariadb-git-9306f55d8e62aca4e00dab3408a8395af85fb947.tar.gz
Many files:
Added key cache assignment mi_locking.c: Added key cache assignment: correction my_sys.h: Added key cache variable structure
Diffstat (limited to 'myisam/mi_extra.c')
-rw-r--r--myisam/mi_extra.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/myisam/mi_extra.c b/myisam/mi_extra.c
index f0d8966c9e3..40bfd0edd30 100644
--- a/myisam/mi_extra.c
+++ b/myisam/mi_extra.c
@@ -279,7 +279,7 @@ int mi_extra(MI_INFO *info, enum ha_extra_function function, void *extra_arg)
#ifdef __WIN__
/* Close the isam and data files as Win32 can't drop an open table */
pthread_mutex_lock(&share->intern_lock);
- if (flush_key_blocks(dflt_keycache, share->kfile,
+ if (flush_key_blocks(*share->keycache, share->kfile,
(function == HA_EXTRA_FORCE_REOPEN ?
FLUSH_RELEASE : FLUSH_IGNORE_CHANGED)))
{
@@ -325,7 +325,7 @@ int mi_extra(MI_INFO *info, enum ha_extra_function function, void *extra_arg)
break;
case HA_EXTRA_FLUSH:
if (!share->temporary)
- flush_key_blocks(dflt_keycache,share->kfile,FLUSH_KEEP);
+ flush_key_blocks(*share->keycache,share->kfile,FLUSH_KEEP);
#ifdef HAVE_PWRITE
_mi_decrement_open_count(info);
#endif
@@ -370,6 +370,9 @@ int mi_extra(MI_INFO *info, enum ha_extra_function function, void *extra_arg)
case HA_EXTRA_PRELOAD_BUFFER_SIZE:
info->preload_buff_size= *((ulong *) extra_arg);
break;
+ case HA_EXTRA_SET_KEY_CACHE:
+ share->reg_keycache= share->keycache= (KEY_CACHE_HANDLE *) extra_arg;
+ break;
case HA_EXTRA_KEY_CACHE:
case HA_EXTRA_NO_KEY_CACHE:
default: