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: 7 Jan 2008 23:00:23 -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-07 23:00 -------
This is a may fail error, not a shall fail error. Testing whether something
is uninitialized or not is very expensive, you can't use for it any bit
in pthread_cond_t itself, since uninitialized var can have any value in it,
you'd need on the side hashtable and that wouldn't work with process shared
condvars. It is simply undefined behavior to use uninitialized condvars
(and similarly for many other data structures).
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |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.