summaryrefslogtreecommitdiff
path: root/mysys/my_static.c
diff options
context:
space:
mode:
authorMichael Widenius <monty@askmonty.org>2011-09-02 12:41:20 +0300
committerMichael Widenius <monty@askmonty.org>2011-09-02 12:41:20 +0300
commit13e4d54795c2e49e4a8654964de1ab899eae2b23 (patch)
tree1b44a4a1a65f94e6bec7900078001cbfee820eac /mysys/my_static.c
parent37a8497d494ea256ff4b13a89e62150e06a17dae (diff)
downloadmariadb-git-13e4d54795c2e49e4a8654964de1ab899eae2b23.tar.gz
Fixed lp:814238 "safe_mutex issues must be assertions in debug binary"
Added --debug-assert-on-error variable which, if set, will cause safe_mutex to assert if it founds an error. include/my_sys.h: Added my_assert_on_error mysys/my_static.c: Added my_assert_on_error mysys/thr_mutex.c: Assert when found wrong mutex usage if my_assert_on_error is set sql/mysqld.cc: Added setting of my_assert_on_error
Diffstat (limited to 'mysys/my_static.c')
-rw-r--r--mysys/my_static.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mysys/my_static.c b/mysys/my_static.c
index 07e106cb1ea..c519542c6f6 100644
--- a/mysys/my_static.c
+++ b/mysys/my_static.c
@@ -32,7 +32,8 @@ char NEAR curr_dir[FN_REFLEN]= {0},
ulong my_stream_opened=0,my_file_opened=0, my_tmp_file_created=0;
ulong my_file_total_opened= 0;
int NEAR my_umask=0664, NEAR my_umask_dir=0777;
-myf my_global_flags;
+myf my_global_flags= 0;
+my_bool my_assert_on_error= 0;
#ifndef THREAD
int NEAR my_errno=0;
#endif