diff options
author | José Fonseca <[email protected]> | 2014-03-03 15:06:19 +0000 |
---|---|---|
committer | José Fonseca <[email protected]> | 2014-03-04 12:05:23 +0000 |
commit | a61d859519d520b849c11ad5c1c1972870abd956 (patch) | |
tree | 8fdb02889bc8c4e81b1aaac33ce979855f2ee359 /configure.ac | |
parent | e8d85034dad37177fce780ee3e09501e60be6e81 (diff) |
c11/threads: Don't implement thrd_current on Windows.
GetCurrentThread() returns a pseudo-handle (a constant which only makes
sense when used within the calling thread) and not a real handle.
DuplicateHandle() will return a real handle, but it will create a new
handle every time we call. Calling DuplicateHandle() here means we will
leak handles, which can cause serious problems.
In short, the Windows implementation of thrd_t needs a thorough make
over, and it won't be pretty. It looks like C11 committee
over-simplified things: it would be much better to have seperate objects
for threads and thread IDs like C++11 does.
For now, just comment out the thrd_current() implementation, so we get
build errors if anybody tries to use it.
Thanks to Brian Paul for spotting and diagnosing this problem.
Cc: "10.0" "10.1" <[email protected]>
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'configure.ac')
0 files changed, 0 insertions, 0 deletions