I currently have an application based on NSS and I am trying to track
down a small, but significant memory leak.
I am using valgrind at the moment to help and upon termination.  I get
the following traceback to a function as a memory leak.  Anyone have
any suggestions about what could be going on here?


==29380== 104 (48 direct, 56 indirect) bytes in 2 blocks are definitely
lost in loss record 29 of 67
==29380==    at 0x1B90727A: calloc (vg_replace_malloc.c:176)
==29380==    by 0x1BE337DB: PR_Calloc (prmem.c:440)
==29380==    by 0x1BCFEA0A: nss_ZAlloc (arena.c:888)
==29380==    by 0x1BCFB104: nssCryptokiObject_Clone (devutil.c:100)
==29380==    by 0x1BCF624B: get_cert_instance (pki3hack.c:584)
==29380==    by 0x1BCF6414: STAN_GetCERTCertificateName
(pki3hack.c:652)
==29380==    by 0x1BC96029: CollectNicknames (certhigh.c:421)
==29380==    by 0x1BCF4C13: nssPKIObjectCollection_Traverse
(pkibase.c:893)
==29380==    by 0x1BCF076B: NSSTrustDomain_TraverseCertificates
(trustdomain.c:1060)
==29380==    by 0x1BC96223: CERT_GetCertNicknames (certhigh.c:496)

This is only snippet that I can put, but the real problem is that I am
callind FreeCertNicknames on the memory allocated here.  Is there
anything else that I am doing wrong?  I have actually run a test where
I used a pointer retrieved by this function and immediately called
FreeCertNicknames on it and valgrind pointed to that as a leak.

-David

_______________________________________________
mozilla-crypto mailing list
[email protected]
http://mail.mozilla.org/listinfo/mozilla-crypto

Reply via email to