Fix a memory leak in SSL.
authorRichard Levitte <levitte@openssl.org>
Thu, 30 Jan 2003 11:00:37 +0000 (11:00 +0000)
committerRichard Levitte <levitte@openssl.org>
Thu, 30 Jan 2003 11:00:37 +0000 (11:00 +0000)
PR: 477

ssl/ssl_lib.c

index 12c4488c3cbd2822755540085803e19e6782520f..ddd811458779a11783ec9ce0d322b28faf3a6120 100644 (file)
@@ -1896,6 +1896,7 @@ SSL *SSL_dup(SSL *s)
                 * they should not both point to the same object,
                 * and thus we can't use SSL_copy_session_id. */
 
+               ret->method->ssl_free(ret);
                ret->method = s->method;
                ret->method->ssl_new(ret);