Closed Bug 1365856 Opened 7 years ago Closed 7 years ago

Fix double-checked-locking in secoid.c

Categories

(NSS :: Libraries, enhancement)

3.31
enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: franziskus, Assigned: franziskus)

Details

From bug 721710 comment 35

> This looks wrong (infamous double-checked-locking)
> 
>     if (dynOidHash) {
>         NSSRWLock_LockRead(dynOidLock);
>         if (dynOidHash) { /* must check it again with lock held. */
>  
> and
> 
>     if (dynOidTable) {
>         NSSRWLock_LockRead(dynOidLock);
>         if (dynOidTable != NULL && /* must check it again with lock held. */
https://hg.mozilla.org/projects/nss/rev/ce74fb260bc4f9870f2312ff6498092f28443983
Assignee: nobody → franziskuskiefer
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → 3.33
You need to log in before you can comment on or make changes to this bug.