Fix for bug 399304 . Replace use of nss_InitLock with PZ_NewLock . Patch contributed by Wan-Teh . r=julien,nelson NSS_3_11_BRANCH
authorjulien.pierre.boogz%sun.com
Thu, 15 Nov 2007 22:05:01 +0000
branchNSS_3_11_BRANCH
changeset 8230 fc9f234810e92c066b07f0f19e2683438d08d7cb
parent 8229 367f6ec660816c80a94bcb83ac43b322166154c0
child 8232 5df61ac3500c7cbae3c752c638a14c21d7265f71
push idunknown
push userunknown
push dateunknown
reviewersjulien, nelson
bugs399304
Fix for bug 399304 . Replace use of nss_InitLock with PZ_NewLock . Patch contributed by Wan-Teh . r=julien,nelson
security/nss/lib/certdb/certdb.c
--- a/security/nss/lib/certdb/certdb.c
+++ b/security/nss/lib/certdb/certdb.c
@@ -2777,25 +2777,25 @@ CERT_LockCertTrust(CERTCertificate *cert
     PZ_Lock(certTrustLock);
     return;
 }
 
 SECStatus
 cert_InitLocks(void)
 {
     if ( certRefCountLock == NULL ) {
-        nss_InitLock(&certRefCountLock, nssILockRefLock);
+        certRefCountLock = PZ_NewLock(nssILockRefLock);
         PORT_Assert(certRefCountLock != NULL);
         if (!certRefCountLock) {
             return SECFailure;
         }
     }
 
     if ( certTrustLock == NULL ) {
-        nss_InitLock(&certTrustLock, nssILockCertDB);
+        certTrustLock = PZ_NewLock(nssILockCertDB);
         PORT_Assert(certTrustLock != NULL);
         if (!certTrustLock) {
             PZ_DestroyLock(certRefCountLock);
             return SECFailure;
         }
     }    
 
     return SECSuccess;