diff options
author | J.C. Jones <jjones@mozilla.com> | 2019-12-06 15:36:44 +0100 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-12-06 15:36:44 +0100 |
commit | 836e72e96caf47add72a13a715722fad030f196c (patch) | |
tree | 7a9a2aeb77ea0e04ac1fc2779dd3cea591a0623e /security/nss/lib/softoken/pkcs11i.h | |
parent | d558cf6647406bdbb87c852772ad211670eff223 (diff) | |
download | UXP-836e72e96caf47add72a13a715722fad030f196c.tar UXP-836e72e96caf47add72a13a715722fad030f196c.tar.gz UXP-836e72e96caf47add72a13a715722fad030f196c.tar.lz UXP-836e72e96caf47add72a13a715722fad030f196c.tar.xz UXP-836e72e96caf47add72a13a715722fad030f196c.zip |
[NSS] Bug 1508776 - Remove unneeded refcounting from SFTKSession
SFTKSession objects are only ever actually destroyed at PK11 session
closure, as the session is always the final holder -- and asserting
refCount == 1 shows that to be true. Because of that, NSC_CloseSession
can just call `sftk_DestroySession` directly and leave
`sftk_FreeSession` as a no-op to be removed in the future.
Diffstat (limited to 'security/nss/lib/softoken/pkcs11i.h')
-rw-r--r-- | security/nss/lib/softoken/pkcs11i.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/nss/lib/softoken/pkcs11i.h b/security/nss/lib/softoken/pkcs11i.h index 7e57dc5e5..1ba0bdb82 100644 --- a/security/nss/lib/softoken/pkcs11i.h +++ b/security/nss/lib/softoken/pkcs11i.h @@ -281,7 +281,6 @@ struct SFTKSessionStr { SFTKSession *next; SFTKSession *prev; CK_SESSION_HANDLE handle; - int refCount; PZLock *objectLock; int objectIDCount; CK_SESSION_INFO info; @@ -670,6 +669,7 @@ extern SFTKSlot *sftk_SlotFromSessionHandle(CK_SESSION_HANDLE handle); extern CK_SLOT_ID sftk_SlotIDFromSessionHandle(CK_SESSION_HANDLE handle); extern SFTKSession *sftk_SessionFromHandle(CK_SESSION_HANDLE handle); extern void sftk_FreeSession(SFTKSession *session); +extern void sftk_DestroySession(SFTKSession *session); extern SFTKSession *sftk_NewSession(CK_SLOT_ID slotID, CK_NOTIFY notify, CK_VOID_PTR pApplication, CK_FLAGS flags); extern void sftk_update_state(SFTKSlot *slot, SFTKSession *session); |