Fixed type defintion for os_thread_id_t on 64 bit Windows.
It used to be declared as ulint, which is 32/64 bit integer depending on OS bitness. However this declaration lead to problems with os_compare_and_swap_thread_id implementation which operated on 32 bit integers (InterlockedCompareExchange) Using 64 bit int lead to wrong result in os_compare_and_swap_thread_id and to crash/assertion in rw_lock_set_writer_id_and_recursion_flag() The fix is to use 4 byte integer to os_thread_id type definition.
This commit is contained in:
parent
768bbae90e
commit
00182614bd
@ -44,7 +44,7 @@ can wait inside InnoDB */
|
|||||||
|
|
||||||
#ifdef __WIN__
|
#ifdef __WIN__
|
||||||
typedef void* os_thread_t;
|
typedef void* os_thread_t;
|
||||||
typedef ulint os_thread_id_t; /*!< In Windows the thread id
|
typedef unsigned long os_thread_id_t; /*!< In Windows the thread id
|
||||||
is an unsigned long int */
|
is an unsigned long int */
|
||||||
#else
|
#else
|
||||||
typedef pthread_t os_thread_t;
|
typedef pthread_t os_thread_t;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user