http://llvm.org/bugs/show_bug.cgi?id=6297
Summary: RWMutex.cpp and pthread on mingw
Product: libraries
Version: trunk
Platform: PC
OS/Version: Windows NT
Status: NEW
Severity: major
Priority: P2
Component: Core LLVM classes
AssignedTo: [email protected]
ReportedBy: [email protected]
CC: [email protected]
Hi,
on mingw platform RWMUtex.cpp asserts L87 due to the fact pthread doesnt'
support passing a non zero value to pthread_rwlock_init.
Here is a fix(tested):
$ svn diff RWMutex.cpp
Index: RWMutex.cpp
===================================================================
--- RWMutex.cpp (revision 96005)
+++ RWMutex.cpp (working copy)
@@ -83,7 +83,11 @@
#endif
// Initialize the rwlock
+#ifdef __MINGW32__
+ errorcode = pthread_rwlock_init(rwlock, 0);
+#else
errorcode = pthread_rwlock_init(rwlock, &attr);
+#endif
assert(errorcode == 0);
// Destroy the attributes
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs