[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
libldap_r
- To: OpenLDAP Devel <openldap-devel@openldap.org>
- Subject: libldap_r
- From: Howard Chu <hyc@symas.com>
- Date: Thu, 24 Sep 2009 16:50:25 -0700
- User-agent: Mozilla/5.0 (X11; U; Linux x86_64; rv:1.9.1b5pre) Gecko/20090909 SeaMonkey/2.0a1pre Firefox/3.0.3
It seems the dichotomy between libldap and libldap_r is a relic from the bad
old days of dcethreads / cmathreads when linking a threaded library into an
otherwise non-threaded program would cause all sorts of strange and wonderful
failures. Unless anyone knows of any current platform where this is unsafe, I
think it's time we dropped this distinction, and just use libldap_r (until we
get to writing a completely new C API).
libldap_r is still missing some thread-specific features though - we should
wrap all library initialization in a pthread_once() call, and we should be
using thread-specific data for the LDAP* errno value.
--
-- Howard Chu
CTO, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc/
Chief Architect, OpenLDAP http://www.openldap.org/project/