diff options
author | unknown <malff/marcsql@weblab.(none)> | 2007-05-22 16:19:36 -0600 |
---|---|---|
committer | unknown <malff/marcsql@weblab.(none)> | 2007-05-22 16:19:36 -0600 |
commit | e5fe02615e71ac59d2f9577e199a0c95d5021408 (patch) | |
tree | d056c801f32fa6eeb6616b1d1e7c2991df4f516d /include/my_pthread.h | |
parent | 2e6e572f994cd0c458e35847d81d00e45af340f2 (diff) | |
download | mariadb-git-e5fe02615e71ac59d2f9577e199a0c95d5021408.tar.gz |
build break cleanup
include/config-win.h:
cleanup, windows build break
include/my_pthread.h:
cleanup, windows build break
sql/event_queue.cc:
warnings cleanup, unititialized waiting_on_cond
tests/mysql_client_test.c:
warnings cleanup
Diffstat (limited to 'include/my_pthread.h')
-rw-r--r-- | include/my_pthread.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/my_pthread.h b/include/my_pthread.h index ef52bbcb16c..e282d16fa12 100644 --- a/include/my_pthread.h +++ b/include/my_pthread.h @@ -722,17 +722,25 @@ extern uint thd_lib_detected; Warning: When compiling without threads, this file is not included. See the *other* declarations of thread_safe_xxx in include/my_global.h + + Second warning: + See include/config-win.h, for yet another implementation. */ #ifdef THREAD +#ifndef thread_safe_increment #define thread_safe_increment(V,L) \ (pthread_mutex_lock((L)), (V)++, pthread_mutex_unlock((L))) #define thread_safe_decrement(V,L) \ (pthread_mutex_lock((L)), (V)--, pthread_mutex_unlock((L))) +#endif + +#ifndef thread_safe_add #define thread_safe_add(V,C,L) \ (pthread_mutex_lock((L)), (V)+=(C), pthread_mutex_unlock((L))) #define thread_safe_sub(V,C,L) \ (pthread_mutex_lock((L)), (V)-=(C), pthread_mutex_unlock((L))) #endif +#endif /* statistics_xxx functions are for non critical statistic, |