Commit 5288f8c0 authored by Michael Widenius's avatar Michael Widenius

Fixed compiler failures when compiling non debug build

storage/maria/ha_maria.cc:
  Don't use 'trn' variable to avoid warning about not used variable
storage/maria/ma_delete.c:
  Added __attribute__((unused))
storage/maria/ma_key_recover.c:
  Added __attribute__((unused))
  Fixed wrong placement of #endif
storage/maria/ma_key_recover.h:
  Fixed typo
parent 4ccb89be
......@@ -2352,9 +2352,9 @@ int ha_maria::reset(void)
{
if (file->trn)
{
TRN *trn= file->trn;
/* Next statement is a new statement. Ensure it's logged */
trnman_set_flags(trn, trnman_get_flags(trn) & ~TRN_STATE_INFO_LOGGED);
trnman_set_flags(file->trn,
trnman_get_flags(file->trn) & ~TRN_STATE_INFO_LOGGED);
}
return maria_reset(file);
}
......
......@@ -1445,7 +1445,7 @@ static uint remove_key(MARIA_KEYDEF *keyinfo, uint page_flag, uint nod_flag,
my_bool _ma_log_delete(MARIA_PAGE *ma_page, const uchar *key_pos,
uint changed_length, uint move_length,
uint append_length,
uint append_length __attribute__((unused)),
enum en_key_debug debug_marker __attribute__((unused)))
{
LSN lsn;
......
......@@ -486,8 +486,8 @@ my_bool _ma_log_suffix(MARIA_PAGE *ma_page, uint org_length, uint new_length)
*/
my_bool _ma_log_add(MARIA_PAGE *ma_page,
uint org_page_length, uchar *key_pos,
uint changed_length, int move_length,
uint org_page_length __attribute__ ((unused)),
uchar *key_pos, uint changed_length, int move_length,
my_bool handle_overflow __attribute__ ((unused)))
{
LSN lsn;
......@@ -670,10 +670,11 @@ void _ma_log_key_changes(MARIA_PAGE *ma_page, LEX_CUSTRING *log_array,
log_array[1].length= page_length;
(*changed_length)+= page_length;
(*translog_parts)++;
#endif
#endif
#endif /* EXTRA_STORE_FULL_PAGE_IN_KEY_CHANGES */
}
#endif /* EXTRA_DEBUG_KEY_CHANGES */
/****************************************************************************
Redo of key pages
****************************************************************************/
......
......@@ -82,7 +82,7 @@ void _ma_log_key_changes(MARIA_PAGE *ma_page, LEX_CUSTRING *log_array,
uchar *log_pos, uint *changed_length,
uint *translog_parts);
#else
void _ma_log_key_changes(A,B,C,D,E)
#define _ma_log_key_changes(A,B,C,D,E)
#endif
uint _ma_apply_redo_index_new_page(MARIA_HA *info, LSN lsn,
......
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