projects
/
libdcp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9161e5c
)
Fix incorrect free and leak.
author
Carl Hetherington
<cth@carlh.net>
Mon, 8 Jul 2013 19:57:04 +0000
(20:57 +0100)
committer
Carl Hetherington
<cth@carlh.net>
Mon, 8 Jul 2013 19:57:04 +0000
(20:57 +0100)
src/certificates.cc
patch
|
blob
|
history
diff --git
a/src/certificates.cc
b/src/certificates.cc
index 085e462272130bd2b39c4d2878630a3211ec9c14..3566fba01e4ee2a5a4c7473f26eaba5812aa36fb 100644
(file)
--- a/
src/certificates.cc
+++ b/
src/certificates.cc
@@
-97,10
+97,10
@@
Certificate::issuer () const
string
Certificate::asn_to_utf8 (ASN1_STRING* s)
{
- unsigned char* buf =
new unsigned char[256]
;
+ unsigned char* buf =
0
;
ASN1_STRING_to_UTF8 (&buf, s);
string const u (reinterpret_cast<char *> (buf));
-
delete[] buf
;
+
OPENSSL_free (buf)
;
return u;
}