branches/zip: Clean up debug code.

struct mtr_struct: Omit unused field "state" unless #ifdef UNIV_DEBUG.

buf_block_buf_fix_inc_debug(): Remove redundant __attribute__((unused))
and #ifdef UNIV_SYNC_DEBUG.
This commit is contained in:
marko 2006-08-16 09:35:36 +00:00
parent 2a70318e38
commit 5e19de2b95
2 changed files with 5 additions and 5 deletions

View file

@ -522,16 +522,14 @@ void
buf_block_buf_fix_inc_debug(
/*========================*/
buf_block_t* block, /* in: block to bufferfix */
const char* file __attribute__ ((unused)), /* in: file name */
ulint line __attribute__ ((unused))) /* in: line */
const char* file, /* in: file name */
ulint line) /* in: line */
{
#ifdef UNIV_SYNC_DEBUG
ibool ret;
ret = rw_lock_s_lock_func_nowait(&(block->debug_latch), file, line);
ut_a(ret);
ut_ad(ret == TRUE);
#endif
block->buf_fix_count++;
}
#else /* UNIV_SYNC_DEBUG */

View file

@ -323,7 +323,9 @@ struct mtr_memo_slot_struct{
/* Mini-transaction handle and buffer */
struct mtr_struct{
#ifdef UNIV_DEBUG
ulint state; /* MTR_ACTIVE, MTR_COMMITTING, MTR_COMMITTED */
#endif
dyn_array_t memo; /* memo stack for locks etc. */
dyn_array_t log; /* mini-transaction log */
ibool modifications;