From: Jouni Malinen Date: Sun, 20 Dec 2009 17:12:59 +0000 (+0200) Subject: OpenSSL: Fix memleak in previous wpabuf changes on an error path X-Git-Tag: hostap_0_7_1~281 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a86a7316a40bd5f17005340c8d981cb32ad1f0ca;p=thirdparty%2Fhostap.git OpenSSL: Fix memleak in previous wpabuf changes on an error path --- diff --git a/src/crypto/tls_openssl.c b/src/crypto/tls_openssl.c index 689e6aac0..cc67938ac 100644 --- a/src/crypto/tls_openssl.c +++ b/src/crypto/tls_openssl.c @@ -2207,6 +2207,7 @@ struct wpabuf * tls_connection_decrypt(void *tls_ctx, if (res < 0) { tls_show_errors(MSG_INFO, __func__, "Decryption failed - SSL_read"); + wpabuf_free(buf); return NULL; } wpabuf_put(buf, res);