[Date Prev][Date Next]
Re: (ITS#8719) slapd_crypt() become slow when many ldap cliant connections occur.
- To: openldap-its@OpenLDAP.org
- Subject: Re: (ITS#8719) slapd_crypt() become slow when many ldap cliant connections occur.
- From: firstname.lastname@example.org
- Date: Sun, 03 Sep 2017 11:02:04 +0000
- Auto-submitted: auto-generated (OpenLDAP-ITS)
Yoshinori Nishino wrote:
> Dear Howard-san,
>> There is no issue with thread-safety for ber_strdup. What exact line of memory.c are you talking about?
> I think ber_strdup(), which uses ber_memalloc_x(), is non thread-safe because of the following comment at around line 69 of memory.c:
> /* Note sequence and ber_int_meminuse are counters, but are not
> * thread safe. If you want to use these values for multithreaded applications,
> * you must put mutexes around them, otherwise they will have incorrect values.
> * When debugging, if you sort the debug output, the sequence number will
> * put allocations/frees together. It is then a simple matter to write a script
> * to find any allocations that don't have a buffer free function.
That comment only applies when using LDAP_MEMORY_DEBUG and is irrelevant.
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/