[Bug 198216] According to man page for pthread_cond_destroy it returns EBUSY error code, but it never does

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Thu Mar 5 15:26:17 UTC 2015


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=198216

--- Comment #2 from Konstantin Belousov <kib at FreeBSD.org> ---
(In reply to John Baldwin from comment #1)

Such check is racy on both sides.  It can report that condvar is busy while it
is no longer such, and in reverse, it can delete a condvar which is started
being used.

Of course, if application allows such race, it is buggy.  But my point is that
threading library implementation cannot make this check non-racy without
applicatin cooperation.

That said, I would prefer not to add the check, at least because we cannot
guarantee that EBUSY is returned always, and that what the error is returned,
it actually happen.

Might be, some wording in the man page explaining the details is due.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-doc mailing list