From 2b47832a2d261dbaf735b26e796aa126bccafb20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vicen=C8=9Biu=20Ciorbaru?= Date: Thu, 10 Dec 2015 03:56:31 +0200 Subject: Fixed compilation failure using clang Both aria and myisam storage engines feature a logic path in thr_find_all_keys that leads to undefined behaviour by bypassing the initialization code of variables after my_thread_init(). By refactoring the nested logic into a separate function, this problem is resolved. --- include/myisam.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'include/myisam.h') diff --git a/include/myisam.h b/include/myisam.h index d50b1dc360e..186b049b32e 100644 --- a/include/myisam.h +++ b/include/myisam.h @@ -330,7 +330,8 @@ typedef struct st_sort_info my_off_t filelength, dupp, buff_length; ha_rows max_records; uint current_key, total_keys; - uint got_error, threads_running; + volatile uint got_error; + uint threads_running; myf myf_rw; enum data_file_type new_data_file_type; } MI_SORT_INFO; -- cgit v1.2.1