diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-05-27 16:40:12 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-05-27 16:40:12 +0400 |
commit | d8106205dbe8cc895541bd797510d7bf8bead0ff (patch) | |
tree | 29c35e3b2ae962a5b6242301dd87eaeb501bec81 /source/blender | |
parent | 5d6bdd7c2ea0413b707dd08d3b3b67154ccd9a55 (diff) |
Fix #22401: BLI_thread_is_main function does not work properly on
64-bit Windows, fix provided by Tamito Kajiyama.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenlib/intern/threads.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/source/blender/blenlib/intern/threads.c b/source/blender/blenlib/intern/threads.c index c63ceb1e5b0..0ad6f84e8f0 100644 --- a/source/blender/blenlib/intern/threads.c +++ b/source/blender/blenlib/intern/threads.c @@ -214,10 +214,7 @@ static void *tslot_thread_start(void *tslot_p) } int BLI_thread_is_main(void) { - pthread_t tid; - tid = pthread_self(); - - return !memcmp(&tid, &mainid, sizeof(pthread_t)); + return pthread_equal(pthread_self(), mainid); } void BLI_insert_thread(ListBase *threadbase, void *callerdata) |