| 1 |
diff -up openssl-1.0.0-beta3/ssl/ssl_lib.c.ctx-free openssl-1.0.0-beta3/ssl/ssl_lib.c
|
| 2 |
--- openssl-1.0.0-beta3/ssl/ssl_lib.c.ctx-free 2009-10-08 20:44:26.000000000 +0200
|
| 3 |
+++ openssl-1.0.0-beta3/ssl/ssl_lib.c 2009-10-16 11:56:53.000000000 +0200
|
| 4 |
@@ -556,7 +556,6 @@ void SSL_free(SSL *s)
|
| 5 |
if (s->cert != NULL) ssl_cert_free(s->cert);
|
| 6 |
/* Free up if allocated */
|
| 7 |
|
| 8 |
- if (s->ctx) SSL_CTX_free(s->ctx);
|
| 9 |
#ifndef OPENSSL_NO_TLSEXT
|
| 10 |
if (s->tlsext_hostname)
|
| 11 |
OPENSSL_free(s->tlsext_hostname);
|
| 12 |
@@ -580,6 +579,8 @@ void SSL_free(SSL *s)
|
| 13 |
|
| 14 |
if (s->method != NULL) s->method->ssl_free(s);
|
| 15 |
|
| 16 |
+ if (s->ctx) SSL_CTX_free(s->ctx);
|
| 17 |
+
|
| 18 |
#ifndef OPENSSL_NO_KRB5
|
| 19 |
if (s->kssl_ctx != NULL)
|
| 20 |
kssl_ctx_free(s->kssl_ctx);
|
| 21 |
diff -up openssl-1.0.0-beta3/ssl/s3_lib.c.hbuf-clear openssl-1.0.0-beta3/ssl/s3_lib.c
|
| 22 |
--- openssl-1.0.0-beta3/ssl/s3_lib.c.hbuf-clear 2009-05-28 20:10:47.000000000 +0200
|
| 23 |
+++ openssl-1.0.0-beta3/ssl/s3_lib.c 2009-10-16 09:50:24.000000000 +0200
|
| 24 |
@@ -2211,6 +2211,7 @@ void ssl3_clear(SSL *s)
|
| 25 |
wlen = s->s3->wbuf.len;
|
| 26 |
if (s->s3->handshake_buffer) {
|
| 27 |
BIO_free(s->s3->handshake_buffer);
|
| 28 |
+ s->s3->handshake_buffer = NULL;
|
| 29 |
}
|
| 30 |
if (s->s3->handshake_dgst) {
|
| 31 |
ssl3_free_digest_list(s);
|