mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
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
This commit is contained in:
@@ -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,
|
||||
|
Reference in New Issue
Block a user