1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-30 16:51:41 +00:00

Correct check for invalid semaphore on sem_destroy() (s/==/!=/).

Reported by:	kris
This commit is contained in:
Daniel Eischen 2004-02-05 23:32:45 +00:00
parent 9b705967d2
commit 08a6a888da
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=125509

View File

@ -162,7 +162,7 @@ __sem_destroy(sem_t *sem)
{
int retval;
if (sem_check_validity(sem) == 0)
if (sem_check_validity(sem) != 0)
return (-1);
_pthread_mutex_lock(&(*sem)->lock);