Skip to content

Commit d040c53

Browse files
committed
[Windows] fix thread local storage cleanup
Thread local storage on Windows is based on FLS API, and should not be mixed with TLS.
1 parent 9ebb444 commit d040c53

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

CoreFoundation/Base.subproj/CFPlatform.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -670,7 +670,7 @@ CF_PRIVATE void __CFFinalizeWindowsThreadData() {
670670
// <rdar://problem/9326814> SyncUIHandler crashes after conflict is resolved and we do SyncNow
671671
// and a bug in dispatch keeps us from using pthreadsWin32 directly, because it does not deal with the case of a dispatch_async happening during process exit (it attempts to create a thread, but that is illegal on Win32 and causes a hang).
672672
// So instead we just finalize once, which is the behavior pre-Airwolf anyway
673-
__CFTSDFinalize(TlsGetValue(__CFTSDIndexKey));
673+
__CFTSDFinalize(FlsGetValue(__CFTSDIndexKey));
674674
}
675675

676676
#else

0 commit comments

Comments
 (0)