diff options
Diffstat (limited to 'ssl/ssl_lib.c')
-rw-r--r-- | ssl/ssl_lib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 4dfd7ab7f0..56d7e6c55a 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -272,7 +272,7 @@ SSL *SSL_new(SSL_CTX *ctx) return (NULL); } - s = OPENSSL_malloc(sizeof(SSL)); + s = OPENSSL_malloc(sizeof(*s)); if (s == NULL) goto err; memset(s, 0, sizeof(SSL)); @@ -1844,7 +1844,7 @@ SSL_CTX *SSL_CTX_new(const SSL_METHOD *meth) SSLerr(SSL_F_SSL_CTX_NEW, SSL_R_X509_VERIFICATION_SETUP_PROBLEMS); goto err; } - ret = OPENSSL_malloc(sizeof(SSL_CTX)); + ret = OPENSSL_malloc(sizeof(*ret)); if (ret == NULL) goto err; |