Commit 38b46781 authored by marko@hundin.mysql.fi's avatar marko@hundin.mysql.fi

Many files:

  Remove leading whitespace from lines containing preprocessor directives
Makefile.am:
  Remove univold.i and univoldmysql.i
parent 42b18e6f
...@@ -901,13 +901,13 @@ buf_page_get_gen( ...@@ -901,13 +901,13 @@ buf_page_get_gen(
buf_read_page(space, offset); buf_read_page(space, offset);
#ifdef UNIV_DEBUG #ifdef UNIV_DEBUG
buf_dbg_counter++; buf_dbg_counter++;
if (buf_dbg_counter % 37 == 0) { if (buf_dbg_counter % 37 == 0) {
ut_ad(buf_validate()); ut_ad(buf_validate());
} }
#endif #endif
goto loop; goto loop;
} }
......
...@@ -50,7 +50,7 @@ noinst_HEADERS = btr0btr.h btr0btr.ic btr0cur.h btr0cur.ic \ ...@@ -50,7 +50,7 @@ noinst_HEADERS = btr0btr.h btr0btr.ic btr0cur.h btr0cur.ic \
thr0loc.h thr0loc.ic trx0purge.h trx0purge.ic trx0rec.h \ thr0loc.h thr0loc.ic trx0purge.h trx0purge.ic trx0rec.h \
trx0rec.ic trx0roll.h trx0roll.ic trx0rseg.h trx0rseg.ic \ trx0rec.ic trx0roll.h trx0roll.ic trx0rseg.h trx0rseg.ic \
trx0sys.h trx0sys.ic trx0trx.h trx0trx.ic trx0types.h \ trx0sys.h trx0sys.ic trx0trx.h trx0trx.ic trx0types.h \
trx0undo.h trx0undo.ic univ.i univold.i univoldmysql.i \ trx0undo.h trx0undo.ic univ.i \
usr0sess.h usr0sess.ic usr0types.h ut0byte.h ut0byte.ic \ usr0sess.h usr0sess.ic usr0types.h ut0byte.h ut0byte.ic \
ut0dbg.h ut0lst.h ut0mem.h ut0mem.ic ut0rnd.h ut0rnd.ic \ ut0dbg.h ut0lst.h ut0mem.h ut0mem.ic ut0rnd.h ut0rnd.ic \
ut0sort.h ut0ut.h ut0ut.ic ut0sort.h ut0ut.h ut0ut.ic
......
...@@ -162,7 +162,7 @@ mem_heap_alloc( ...@@ -162,7 +162,7 @@ mem_heap_alloc(
mem_block_set_free(block, free + MEM_SPACE_NEEDED(n)); mem_block_set_free(block, free + MEM_SPACE_NEEDED(n));
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
/* In the debug version write debugging info to the field */ /* In the debug version write debugging info to the field */
mem_field_init((byte*)buf, n); mem_field_init((byte*)buf, n);
...@@ -171,7 +171,7 @@ mem_heap_alloc( ...@@ -171,7 +171,7 @@ mem_heap_alloc(
caller */ caller */
buf = (byte*)buf + MEM_FIELD_HEADER_SIZE; buf = (byte*)buf + MEM_FIELD_HEADER_SIZE;
#endif #endif
#ifdef UNIV_SET_MEM_TO_ZERO #ifdef UNIV_SET_MEM_TO_ZERO
memset(buf, '\0', n); memset(buf, '\0', n);
#endif #endif
...@@ -212,15 +212,15 @@ mem_heap_free_heap_top( ...@@ -212,15 +212,15 @@ mem_heap_free_heap_top(
{ {
mem_block_t* block; mem_block_t* block;
mem_block_t* prev_block; mem_block_t* prev_block;
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
ibool error; ibool error;
ulint total_size; ulint total_size;
ulint size; ulint size;
#endif #endif
ut_ad(mem_heap_check(heap)); ut_ad(mem_heap_check(heap));
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
/* Validate the heap and get its total allocated size */ /* Validate the heap and get its total allocated size */
mem_heap_validate_or_print(heap, NULL, FALSE, &error, &total_size, mem_heap_validate_or_print(heap, NULL, FALSE, &error, &total_size,
...@@ -232,7 +232,7 @@ mem_heap_free_heap_top( ...@@ -232,7 +232,7 @@ mem_heap_free_heap_top(
NULL); NULL);
ut_a(!error); ut_a(!error);
#endif #endif
block = UT_LIST_GET_LAST(heap->base); block = UT_LIST_GET_LAST(heap->base);
...@@ -259,7 +259,7 @@ mem_heap_free_heap_top( ...@@ -259,7 +259,7 @@ mem_heap_free_heap_top(
/* Set the free field of block */ /* Set the free field of block */
mem_block_set_free(block, old_top - (byte*)block); mem_block_set_free(block, old_top - (byte*)block);
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
ut_ad(mem_block_get_start(block) <= mem_block_get_free(block)); ut_ad(mem_block_get_start(block) <= mem_block_get_free(block));
/* In the debug version erase block from top up */ /* In the debug version erase block from top up */
...@@ -271,7 +271,7 @@ mem_heap_free_heap_top( ...@@ -271,7 +271,7 @@ mem_heap_free_heap_top(
mem_current_allocated_memory -= (total_size - size); mem_current_allocated_memory -= (total_size - size);
mutex_exit(&mem_hash_mutex); mutex_exit(&mem_hash_mutex);
#endif #endif
/* If free == start, we may free the block if it is not the first /* If free == start, we may free the block if it is not the first
one */ one */
...@@ -317,7 +317,7 @@ mem_heap_get_top( ...@@ -317,7 +317,7 @@ mem_heap_get_top(
buf = (byte*)block + mem_block_get_free(block) - MEM_SPACE_NEEDED(n); buf = (byte*)block + mem_block_get_free(block) - MEM_SPACE_NEEDED(n);
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
ut_ad(mem_block_get_start(block) <=(ulint)((byte*)buf - (byte*)block)); ut_ad(mem_block_get_start(block) <=(ulint)((byte*)buf - (byte*)block));
/* In the debug version, advance buf to point at the storage which /* In the debug version, advance buf to point at the storage which
...@@ -327,7 +327,7 @@ mem_heap_get_top( ...@@ -327,7 +327,7 @@ mem_heap_get_top(
/* Check that the field lengths agree */ /* Check that the field lengths agree */
ut_ad(n == (ulint)mem_field_header_get_len(buf)); ut_ad(n == (ulint)mem_field_header_get_len(buf));
#endif #endif
return(buf); return(buf);
} }
...@@ -351,13 +351,13 @@ mem_heap_free_top( ...@@ -351,13 +351,13 @@ mem_heap_free_top(
/* Subtract the free field of block */ /* Subtract the free field of block */
mem_block_set_free(block, mem_block_get_free(block) mem_block_set_free(block, mem_block_get_free(block)
- MEM_SPACE_NEEDED(n)); - MEM_SPACE_NEEDED(n));
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
ut_ad(mem_block_get_start(block) <= mem_block_get_free(block)); ut_ad(mem_block_get_start(block) <= mem_block_get_free(block));
/* In the debug version check the consistency, and erase field */ /* In the debug version check the consistency, and erase field */
mem_field_erase((byte*)block + mem_block_get_free(block), n); mem_field_erase((byte*)block + mem_block_get_free(block), n);
#endif #endif
/* If free == start, we may free the block if it is not the first /* If free == start, we may free the block if it is not the first
one */ one */
...@@ -417,7 +417,7 @@ mem_heap_create_func( ...@@ -417,7 +417,7 @@ mem_heap_create_func(
/* Add the created block itself as the first block in the list */ /* Add the created block itself as the first block in the list */
UT_LIST_ADD_FIRST(list, block->base, block); UT_LIST_ADD_FIRST(list, block->base, block);
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
if (block == NULL) { if (block == NULL) {
...@@ -426,7 +426,7 @@ mem_heap_create_func( ...@@ -426,7 +426,7 @@ mem_heap_create_func(
mem_hash_insert(block, file_name, line); mem_hash_insert(block, file_name, line);
#endif #endif
return(block); return(block);
} }
...@@ -452,14 +452,14 @@ mem_heap_free_func( ...@@ -452,14 +452,14 @@ mem_heap_free_func(
block = UT_LIST_GET_LAST(heap->base); block = UT_LIST_GET_LAST(heap->base);
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
/* In the debug version remove the heap from the hash table of heaps /* In the debug version remove the heap from the hash table of heaps
and check its consistency */ and check its consistency */
mem_hash_remove(heap, file_name, line); mem_hash_remove(heap, file_name, line);
#endif #endif
if (heap->free_block) { if (heap->free_block) {
mem_heap_free_block_free(heap); mem_heap_free_block_free(heap);
......
...@@ -140,10 +140,10 @@ rw_lock_s_lock_low( ...@@ -140,10 +140,10 @@ rw_lock_s_lock_low(
/* Set the shared lock by incrementing the reader count */ /* Set the shared lock by incrementing the reader count */
lock->reader_count++; lock->reader_count++;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, pass, RW_LOCK_SHARED, file_name, rw_lock_add_debug_info(lock, pass, RW_LOCK_SHARED, file_name,
line); line);
#endif #endif
lock->last_s_file_name = file_name; lock->last_s_file_name = file_name;
lock->last_s_line = line; lock->last_s_line = line;
...@@ -175,9 +175,9 @@ rw_lock_s_lock_direct( ...@@ -175,9 +175,9 @@ rw_lock_s_lock_direct(
lock->last_s_file_name = file_name; lock->last_s_file_name = file_name;
lock->last_s_line = line; lock->last_s_line = line;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, 0, RW_LOCK_SHARED, file_name, line); rw_lock_add_debug_info(lock, 0, RW_LOCK_SHARED, file_name, line);
#endif #endif
} }
/********************************************************************** /**********************************************************************
...@@ -204,9 +204,9 @@ rw_lock_x_lock_direct( ...@@ -204,9 +204,9 @@ rw_lock_x_lock_direct(
lock->last_x_file_name = file_name; lock->last_x_file_name = file_name;
lock->last_x_line = line; lock->last_x_line = line;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, 0, RW_LOCK_EX, file_name, line); rw_lock_add_debug_info(lock, 0, RW_LOCK_EX, file_name, line);
#endif #endif
} }
/********************************************************************** /**********************************************************************
...@@ -275,10 +275,10 @@ rw_lock_s_lock_func_nowait( ...@@ -275,10 +275,10 @@ rw_lock_s_lock_func_nowait(
/* Set the shared lock by incrementing the reader count */ /* Set the shared lock by incrementing the reader count */
lock->reader_count++; lock->reader_count++;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, 0, RW_LOCK_SHARED, file_name, rw_lock_add_debug_info(lock, 0, RW_LOCK_SHARED, file_name,
line); line);
#endif #endif
lock->last_s_file_name = file_name; lock->last_s_file_name = file_name;
lock->last_s_line = line; lock->last_s_line = line;
...@@ -320,9 +320,9 @@ rw_lock_x_lock_func_nowait( ...@@ -320,9 +320,9 @@ rw_lock_x_lock_func_nowait(
lock->writer_count++; lock->writer_count++;
lock->pass = 0; lock->pass = 0;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, 0, RW_LOCK_EX, file_name, line); rw_lock_add_debug_info(lock, 0, RW_LOCK_EX, file_name, line);
#endif #endif
lock->last_x_file_name = file_name; lock->last_x_file_name = file_name;
lock->last_x_line = line; lock->last_x_line = line;
...@@ -361,9 +361,9 @@ rw_lock_s_unlock_func( ...@@ -361,9 +361,9 @@ rw_lock_s_unlock_func(
ut_a(lock->reader_count > 0); ut_a(lock->reader_count > 0);
lock->reader_count--; lock->reader_count--;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_remove_debug_info(lock, pass, RW_LOCK_SHARED); rw_lock_remove_debug_info(lock, pass, RW_LOCK_SHARED);
#endif #endif
/* If there may be waiters and this was the last s-lock, /* If there may be waiters and this was the last s-lock,
signal the object */ signal the object */
...@@ -402,9 +402,9 @@ rw_lock_s_unlock_direct( ...@@ -402,9 +402,9 @@ rw_lock_s_unlock_direct(
lock->reader_count--; lock->reader_count--;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_remove_debug_info(lock, 0, RW_LOCK_SHARED); rw_lock_remove_debug_info(lock, 0, RW_LOCK_SHARED);
#endif #endif
ut_ad(!lock->waiters); ut_ad(!lock->waiters);
ut_ad(rw_lock_validate(lock)); ut_ad(rw_lock_validate(lock));
...@@ -442,9 +442,9 @@ rw_lock_x_unlock_func( ...@@ -442,9 +442,9 @@ rw_lock_x_unlock_func(
rw_lock_set_writer(lock, RW_LOCK_NOT_LOCKED); rw_lock_set_writer(lock, RW_LOCK_NOT_LOCKED);
} }
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_remove_debug_info(lock, pass, RW_LOCK_EX); rw_lock_remove_debug_info(lock, pass, RW_LOCK_EX);
#endif #endif
/* If there may be waiters, signal the lock */ /* If there may be waiters, signal the lock */
if (lock->waiters && (lock->writer_count == 0)) { if (lock->waiters && (lock->writer_count == 0)) {
...@@ -486,9 +486,9 @@ rw_lock_x_unlock_direct( ...@@ -486,9 +486,9 @@ rw_lock_x_unlock_direct(
rw_lock_set_writer(lock, RW_LOCK_NOT_LOCKED); rw_lock_set_writer(lock, RW_LOCK_NOT_LOCKED);
} }
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_remove_debug_info(lock, 0, RW_LOCK_EX); rw_lock_remove_debug_info(lock, 0, RW_LOCK_EX);
#endif #endif
ut_ad(!lock->waiters); ut_ad(!lock->waiters);
ut_ad(rw_lock_validate(lock)); ut_ad(rw_lock_validate(lock));
......
...@@ -250,9 +250,9 @@ mutex_enter_func( ...@@ -250,9 +250,9 @@ mutex_enter_func(
if (!mutex_test_and_set(mutex)) { if (!mutex_test_and_set(mutex)) {
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
mutex_set_debug_info(mutex, file_name, line); mutex_set_debug_info(mutex, file_name, line);
#endif #endif
mutex->file_name = file_name; mutex->file_name = file_name;
mutex->line = line; mutex->line = line;
......
...@@ -176,19 +176,19 @@ ut_fold_string( ...@@ -176,19 +176,19 @@ ut_fold_string(
/* out: folded value */ /* out: folded value */
char* str) /* in: null-terminated string */ char* str) /* in: null-terminated string */
{ {
#ifdef UNIV_DEBUG #ifdef UNIV_DEBUG
ulint i = 0; ulint i = 0;
#endif #endif
ulint fold = 0; ulint fold = 0;
ut_ad(str); ut_ad(str);
while (*str != '\0') { while (*str != '\0') {
#ifdef UNIV_DEBUG #ifdef UNIV_DEBUG
i++; i++;
ut_a(i < 100); ut_a(i < 100);
#endif #endif
fold = ut_fold_ulint_pair(fold, (ulint)(*str)); fold = ut_fold_ulint_pair(fold, (ulint)(*str));
str++; str++;
......
...@@ -406,12 +406,12 @@ mem_heap_validate_or_print( ...@@ -406,12 +406,12 @@ mem_heap_validate_or_print(
ulint total_len = 0; ulint total_len = 0;
ulint block_count = 0; ulint block_count = 0;
ulint phys_len = 0; ulint phys_len = 0;
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
ulint len; ulint len;
byte* field; byte* field;
byte* user_field; byte* user_field;
ulint check_field; ulint check_field;
#endif #endif
/* Pessimistically, we set the parameters to error values */ /* Pessimistically, we set the parameters to error values */
if (us_size != NULL) { if (us_size != NULL) {
...@@ -446,7 +446,7 @@ mem_heap_validate_or_print( ...@@ -446,7 +446,7 @@ mem_heap_validate_or_print(
return; return;
} }
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
/* We can trace the fields of the block only in the debug /* We can trace the fields of the block only in the debug
version */ version */
if (print) { if (print) {
...@@ -502,7 +502,7 @@ mem_heap_validate_or_print( ...@@ -502,7 +502,7 @@ mem_heap_validate_or_print(
return; return;
} }
#endif #endif
block = UT_LIST_GET_NEXT(list, block); block = UT_LIST_GET_NEXT(list, block);
block_count++; block_count++;
...@@ -714,7 +714,7 @@ mem_all_freed(void) ...@@ -714,7 +714,7 @@ mem_all_freed(void)
/*===============*/ /*===============*/
/* out: TRUE if no heaps exist */ /* out: TRUE if no heaps exist */
{ {
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
mem_hash_node_t* node; mem_hash_node_t* node;
ulint heap_count = 0; ulint heap_count = 0;
...@@ -744,14 +744,14 @@ mem_all_freed(void) ...@@ -744,14 +744,14 @@ mem_all_freed(void)
return(FALSE); return(FALSE);
} }
#else #else
printf( printf(
"Sorry, non-debug version cannot check if all memory is freed.\n"); "Sorry, non-debug version cannot check if all memory is freed.\n");
return(FALSE); return(FALSE);
#endif #endif
} }
/********************************************************************* /*********************************************************************
...@@ -762,7 +762,7 @@ mem_validate_no_assert(void) ...@@ -762,7 +762,7 @@ mem_validate_no_assert(void)
/*========================*/ /*========================*/
/* out: TRUE if error */ /* out: TRUE if error */
{ {
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
mem_hash_node_t* node; mem_hash_node_t* node;
ulint n_heaps = 0; ulint n_heaps = 0;
...@@ -823,13 +823,13 @@ mem_validate_no_assert(void) ...@@ -823,13 +823,13 @@ mem_validate_no_assert(void)
return(error); return(error);
#else #else
printf("Sorry, non-debug version cannot validate dynamic memory\n"); printf("Sorry, non-debug version cannot validate dynamic memory\n");
return(FALSE); return(FALSE);
#endif #endif
} }
/**************************************************************** /****************************************************************
......
...@@ -294,13 +294,13 @@ mem_heap_block_free( ...@@ -294,13 +294,13 @@ mem_heap_block_free(
init_block = block->init_block; init_block = block->init_block;
block->magic_n = MEM_FREED_BLOCK_MAGIC_N; block->magic_n = MEM_FREED_BLOCK_MAGIC_N;
#ifdef UNIV_MEM_DEBUG #ifdef UNIV_MEM_DEBUG
/* In the debug version we set the memory to a random combination /* In the debug version we set the memory to a random combination
of hex 0xDE and 0xAD. */ of hex 0xDE and 0xAD. */
mem_erase_buf((byte*)block, len); mem_erase_buf((byte*)block, len);
#endif #endif
if (init_block) { if (init_block) {
/* Do not have to free: do nothing */ /* Do not have to free: do nothing */
......
...@@ -318,10 +318,10 @@ rw_lock_x_lock_low( ...@@ -318,10 +318,10 @@ rw_lock_x_lock_low(
lock->writer_count++; lock->writer_count++;
lock->pass = pass; lock->pass = pass;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, pass, RW_LOCK_EX, rw_lock_add_debug_info(lock, pass, RW_LOCK_EX,
file_name, line); file_name, line);
#endif #endif
lock->last_x_file_name = file_name; lock->last_x_file_name = file_name;
lock->last_x_line = line; lock->last_x_line = line;
...@@ -334,10 +334,10 @@ rw_lock_x_lock_low( ...@@ -334,10 +334,10 @@ rw_lock_x_lock_low(
lock->pass = pass; lock->pass = pass;
lock->writer_is_wait_ex = TRUE; lock->writer_is_wait_ex = TRUE;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, pass, RW_LOCK_WAIT_EX, rw_lock_add_debug_info(lock, pass, RW_LOCK_WAIT_EX,
file_name, line); file_name, line);
#endif #endif
return(RW_LOCK_WAIT_EX); return(RW_LOCK_WAIT_EX);
} }
...@@ -353,11 +353,11 @@ rw_lock_x_lock_low( ...@@ -353,11 +353,11 @@ rw_lock_x_lock_low(
lock->pass = pass; lock->pass = pass;
lock->writer_is_wait_ex = FALSE; lock->writer_is_wait_ex = FALSE;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_remove_debug_info(lock, pass, RW_LOCK_WAIT_EX); rw_lock_remove_debug_info(lock, pass, RW_LOCK_WAIT_EX);
rw_lock_add_debug_info(lock, pass, RW_LOCK_EX, rw_lock_add_debug_info(lock, pass, RW_LOCK_EX,
file_name, line); file_name, line);
#endif #endif
lock->last_x_file_name = file_name; lock->last_x_file_name = file_name;
lock->last_x_line = line; lock->last_x_line = line;
...@@ -376,10 +376,10 @@ rw_lock_x_lock_low( ...@@ -376,10 +376,10 @@ rw_lock_x_lock_low(
lock->writer_count++; lock->writer_count++;
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
rw_lock_add_debug_info(lock, pass, RW_LOCK_EX, file_name, rw_lock_add_debug_info(lock, pass, RW_LOCK_EX, file_name,
line); line);
#endif #endif
lock->last_x_file_name = file_name; lock->last_x_file_name = file_name;
lock->last_x_line = line; lock->last_x_line = line;
......
...@@ -301,9 +301,9 @@ mutex_enter_nowait( ...@@ -301,9 +301,9 @@ mutex_enter_nowait(
if (!mutex_test_and_set(mutex)) { if (!mutex_test_and_set(mutex)) {
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
mutex_set_debug_info(mutex, file_name, line); mutex_set_debug_info(mutex, file_name, line);
#endif #endif
mutex->file_name = file_name; mutex->file_name = file_name;
mutex->line = line; mutex->line = line;
...@@ -402,9 +402,9 @@ mutex_spin_wait( ...@@ -402,9 +402,9 @@ mutex_spin_wait(
if (mutex_test_and_set(mutex) == 0) { if (mutex_test_and_set(mutex) == 0) {
/* Succeeded! */ /* Succeeded! */
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
mutex_set_debug_info(mutex, file_name, line); mutex_set_debug_info(mutex, file_name, line);
#endif #endif
mutex->file_name = file_name; mutex->file_name = file_name;
mutex->line = line; mutex->line = line;
...@@ -449,9 +449,9 @@ mutex_spin_wait( ...@@ -449,9 +449,9 @@ mutex_spin_wait(
sync_array_free_cell(sync_primary_wait_array, index); sync_array_free_cell(sync_primary_wait_array, index);
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
mutex_set_debug_info(mutex, file_name, line); mutex_set_debug_info(mutex, file_name, line);
#endif #endif
mutex->file_name = file_name; mutex->file_name = file_name;
mutex->line = line; mutex->line = line;
...@@ -671,18 +671,18 @@ ibool ...@@ -671,18 +671,18 @@ ibool
sync_all_freed(void) sync_all_freed(void)
/*================*/ /*================*/
{ {
#ifdef UNIV_SYNC_DEBUG #ifdef UNIV_SYNC_DEBUG
if (mutex_n_reserved() + rw_lock_n_locked() == 0) { if (mutex_n_reserved() + rw_lock_n_locked() == 0) {
return(TRUE); return(TRUE);
} else { } else {
return(FALSE); return(FALSE);
} }
#else #else
ut_error; ut_error;
return(FALSE); return(FALSE);
#endif #endif
} }
/********************************************************************** /**********************************************************************
......
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