Andrew Talbot : crypt32: Fix some memory leaks.
Alexandre Julliard
julliard at winehq.org
Mon Sep 17 08:00:00 CDT 2007
Module: wine
Branch: master
Commit: f19086e9d3e51f24fc65a88d4b1a75094dd4da9f
URL: http://source.winehq.org/git/wine.git/?a=commit;h=f19086e9d3e51f24fc65a88d4b1a75094dd4da9f
Author: Andrew Talbot <andrew.talbot at talbotville.com>
Date: Fri Sep 14 17:02:33 2007 +0100
crypt32: Fix some memory leaks.
---
dlls/crypt32/msg.c | 1 +
dlls/crypt32/rootstore.c | 1 +
2 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/dlls/crypt32/msg.c b/dlls/crypt32/msg.c
index 4e608bc..40d8390 100644
--- a/dlls/crypt32/msg.c
+++ b/dlls/crypt32/msg.c
@@ -2079,6 +2079,7 @@ static BOOL CDecodeHashMsg_VerifyHash(CDecodeMsg *msg)
if (ret)
ret = !memcmp(hashBlob.pbData, computedHash,
hashBlob.cbData);
+ CryptMemFree(computedHash);
}
else
ret = FALSE;
diff --git a/dlls/crypt32/rootstore.c b/dlls/crypt32/rootstore.c
index 945b9c8..0bd537d 100644
--- a/dlls/crypt32/rootstore.c
+++ b/dlls/crypt32/rootstore.c
@@ -137,6 +137,7 @@ static BOOL import_base64_certs_from_fp(FILE *fp, HCERTSTORE store)
if (CertAddEncodedCertificateToStore(store,
X509_ASN_ENCODING, buf, size, CERT_STORE_ADD_NEW, NULL))
num_certs++;
+ CryptMemFree(buf);
}
}
}
More information about the wine-cvs
mailing list