NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PR/53998 CVS commit: src/sys/kern

The following reply was made to PR kern/53998; it has been noted by GNATS.

From: Christos Zoulas <>
To: "" <>
Subject: Re: PR/53998 CVS commit: src/sys/kern
Date: Thu, 21 Feb 2019 18:58:55 -0500

 > 	Christos,
 > 	Thanks a lot for this patch, but I'm not really sure it will fix this
 > issue. Of course, with your patch, sem_init() will return ENOSPC instead
 > of -1. but I'm not understand how a memory allocation error can occur in
 > my code. I have verified that my test program doesn't contain memory
 > leak and, when sem_init() fails, system has more than 10GB free.
 > 	Of course, I create a semahore with sem_init() in each thread but I
 > destroy this semaphore also with sem_destroy() (returns 0) before
 > pthread_exit().
 Yes, I understand, I am documenting that this also fails when the
 max number of semaphors is exceeded. So perhaps we have a leak
 somewhere. Can you share your test program?

Home | Main Index | Thread Index | Old Index