From ad4e995faea361470870d8b292253ea11958636c Mon Sep 17 00:00:00 2001 From: Antonio Quartulli Date: Wed, 11 Oct 2017 12:54:46 +0800 Subject: [PATCH] mbedTLS: use mbedtls API to initialize cert object Signed-off-by: Antonio Quartulli --- openvpn/mbedtls/pki/x509cert.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openvpn/mbedtls/pki/x509cert.hpp b/openvpn/mbedtls/pki/x509cert.hpp index 8b2fc985..fab1343d 100644 --- a/openvpn/mbedtls/pki/x509cert.hpp +++ b/openvpn/mbedtls/pki/x509cert.hpp @@ -102,7 +102,7 @@ namespace openvpn { if (!chain) { chain = new mbedtls_x509_crt; - std::memset(chain, 0, sizeof(mbedtls_x509_crt)); + mbedtls_x509_crt_init(chain); } }