[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: (ITS#6745) HEAD emfile race condition -> slapd stopping listening?
- To: openldap-its@OpenLDAP.org
- Subject: Re: (ITS#6745) HEAD emfile race condition -> slapd stopping listening?
- From: hyc@symas.com
- Date: Fri, 24 Dec 2010 01:56:50 GMT
- Auto-submitted: auto-generated (OpenLDAP-ITS)
Howard Chu wrote:
> h.b.furuseth@usit.uio.no wrote:
>> Full_Name: Hallvard B Furuseth
>> Version: HEAD
>> OS:
>> URL:
>> Submission from: (NULL) (129.240.6.233)
>> Submitted by: hallvard
>>
>>
>> In HEAD slapd/daemon.c, thanks to HEAD's multiple listener support:
>>
>> slap_listener() protects emfile with slap_daemon[0 ].sd_mutex,
>> but slapd_remove() protects it with slap_daemon[id].sd_mutex.
>>
>> Maybe to compensate, slapd_remove() has code which checks if emfile
>> is too big, but nothing checks if it is too small - which looks like
>> slapd might never start listening again.
On 2nd thought - I don't see how the outcome you describe can occur. If emfile
is non-zero, the list of listeners will be checked for a listener with
non-zero mute status. If any are found, one is guaranteed to be unmuted. If
none are found, emfile will be zeroed.
In no case will slapd fail to unmute a listener.
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/