Commit 64da2c3f authored by unknown's avatar unknown

If Maria engine is not compiled in, don't use page caches (fix

for compiler errors in pushbuild). Small bugfix.


sql/handler.h:
  don't use pagecaches if no Maria
storage/maria/ma_check.c:
  correcting mistake in previous push; need to call this function
  otherwise create_rename_lsn would not be updated at end of REPAIR.
parent 69d7db77
......@@ -23,7 +23,9 @@
#include <my_handler.h>
#include <ft_global.h>
#include <keycache.h>
#ifdef WITH_MARIA_STORAGE_ENGINE
#include "../storage/maria/ma_pagecache.h"
#endif
#ifndef NO_HASH
#define NO_HASH /* Not yet implemented */
......@@ -859,7 +861,9 @@ typedef struct st_ha_check_opt
uint flags; /* isam layer flags (e.g. for myisamchk) */
uint sql_flags; /* sql layer flags - for something myisamchk cannot do */
KEY_CACHE *key_cache; /* new key cache when changing key cache */
#ifdef WITH_MARIA_STORAGE_ENGINE
PAGECACHE *pagecache; /* new pagecache when changing pagecache */
#endif
void init();
} HA_CHECK_OPT;
......@@ -1818,6 +1822,7 @@ int ha_resize_key_cache(KEY_CACHE *key_cache);
int ha_change_key_cache_param(KEY_CACHE *key_cache);
int ha_change_key_cache(KEY_CACHE *old_key_cache, KEY_CACHE *new_key_cache);
int ha_end_key_cache(KEY_CACHE *key_cache);
#ifdef WITH_MARIA_STORAGE_ENGINE
/* pagecache */
int ha_init_pagecache(const char *name, PAGECACHE *pagecache);
/*
......@@ -1827,6 +1832,7 @@ int ha_resize_pagecache(PAGECACHE *pagecache);
int ha_change_pagecache_param(PAGECACHE *pagecache);
int ha_change_pagecache(PAGECACHE *old_pagecache, PAGECACHE *new_pagecache);
int ha_end_pagecache(PAGECACHE *pagecache);
#endif
/* report to InnoDB that control passes to the client */
int ha_release_temporary_latches(THD *thd);
......
......@@ -5604,6 +5604,10 @@ static int write_log_record_for_repair(const HA_CHECK *param, MARIA_HA *info)
/*
The table's existence was made durable earlier (MY_SYNC_DIR passed to
maria_change_to_newfile()).
*/
if (_ma_update_create_rename_lsn_on_disk(info->s, lsn, FALSE))
return 1;
/*
_ma_flush_table_files_after_repair() is later called by maria_repair(),
and makes sure to flush the data, index, update is_of_lsn, flush state
and sync, so create_rename_lsn reaches disk, thus we won't apply old
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment