libssldap/clientinit.c:inited not protected?
Milan Jurik <[email protected]> Thu, 18 Mar 2010 10:46:14 +0100
| Newsgroups | gmane.comp.mozilla.devel.directory |
|---|---|
| Organization | Sun Microsystems - Prague Czech Republic |
| Message-ID | <1268905574.3135.32.camel@xylabone> |
Hi, I am looking at NSS initialization in libldap and I see that Mozilla libldap is not protecting usage of inited variable: On the beginning it tests for inited value if 0, but value is set much later to 1, so several calls to ldapssl_clientauth_init() or ldapssl_advclientauth_init() or ldapssl_pkcs_init() in parallel can lead to many unnecessary ldapssl_basic_init() calls. Would it be better to use some mutex for protection of it? Best regards, Milan