summaryrefslogtreecommitdiffstats
path: root/net/base/x509_certificate_nss.cc
diff options
context:
space:
mode:
authordkegel@google.com <dkegel@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-18 01:47:46 +0000
committerdkegel@google.com <dkegel@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-03-18 01:47:46 +0000
commit05f3813570e6390c0a138cb79b906a93502aa25d (patch)
tree64cca4de9521038d783beba021d6169700b8d043 /net/base/x509_certificate_nss.cc
parentb2071241671a717c0a484204903ff2ae03510ced (diff)
downloadchromium_src-05f3813570e6390c0a138cb79b906a93502aa25d.zip
chromium_src-05f3813570e6390c0a138cb79b906a93502aa25d.tar.gz
chromium_src-05f3813570e6390c0a138cb79b906a93502aa25d.tar.bz2
Fix leak in GetCertSubjectAltNamesOfType(). Found by valgrind.
ERROR:root:Leak_DefinitelyLost malloc (ome/kcc/depot2-kcc-ts_valgrind-client/google_vendor_src_branch/valgrind/trunk/coregrind/m_replacemalloc/vg_replace_malloc.c:207) ... CERT_FindCertExtension (/usr/lib32/libnss3.so.1d) net::(anonymous namespace)::GetCertSubjectAltNamesOfType(CERTCertificateStr*, CERTGeneralNameTypeEnum, std::vector<std::string, std::allocator<std::string> >*) (net/base/x509_certificate_nss.cc:134) Review URL: http://codereview.chromium.org/48097 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11941 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/x509_certificate_nss.cc')
-rw-r--r--net/base/x509_certificate_nss.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/base/x509_certificate_nss.cc b/net/base/x509_certificate_nss.cc
index e734a6e..6fd5d2c 100644
--- a/net/base/x509_certificate_nss.cc
+++ b/net/base/x509_certificate_nss.cc
@@ -159,6 +159,7 @@ void GetCertSubjectAltNamesOfType(X509Certificate::OSCertHandle cert_handle,
break;
}
PORT_FreeArena(arena, PR_FALSE);
+ PORT_Free(alt_name.data);
}
} // namespace