This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug nptl/5551] pthread_cond_signal() doesn't return EINVAL for uninitialized cond per POSIX.
- From: "jakub at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 30 Jan 2008 15:12:06 -0000
- Subject: [Bug nptl/5551] pthread_cond_signal() doesn't return EINVAL for uninitialized cond per POSIX.
- References: <20080107224605.5551.rsa@us.ibm.com>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From jakub at redhat dot com 2008-01-30 15:12 -------
Your testcase is racy, that's not the fault of libpthread.
If you use a synchronization primitive in several threads (condvar in this case),
then you need to ensure it is already initialized and not yet destroyed when
it is used. That can be done by initializing it prior to starting the threads,
or by using some locking, barriers, etc.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution| |INVALID
http://sourceware.org/bugzilla/show_bug.cgi?id=5551
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.