diff options
Diffstat (limited to 'src/lib/libssl/ssl_lib.c')
| -rw-r--r-- | src/lib/libssl/ssl_lib.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/lib/libssl/ssl_lib.c b/src/lib/libssl/ssl_lib.c index 6479f729e7..d37f305387 100644 --- a/src/lib/libssl/ssl_lib.c +++ b/src/lib/libssl/ssl_lib.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: ssl_lib.c,v 1.114 2015/10/16 14:23:22 beck Exp $ */ | 1 | /* $OpenBSD: ssl_lib.c,v 1.115 2015/10/19 17:59:39 beck Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -503,9 +503,9 @@ SSL_free(SSL *s) | |||
| 503 | s->bbio = NULL; | 503 | s->bbio = NULL; |
| 504 | } | 504 | } |
| 505 | 505 | ||
| 506 | if (s->wbio != s->rbio) | 506 | if (s->rbio != s->wbio) |
| 507 | BIO_free_all(s->wbio); | 507 | BIO_free_all(s->rbio); |
| 508 | BIO_free_all(s->rbio); | 508 | BIO_free_all(s->wbio); |
| 509 | 509 | ||
| 510 | if (s->init_buf != NULL) | 510 | if (s->init_buf != NULL) |
| 511 | BUF_MEM_free(s->init_buf); | 511 | BUF_MEM_free(s->init_buf); |
| @@ -572,10 +572,10 @@ SSL_set_bio(SSL *s, BIO *rbio, BIO *wbio) | |||
| 572 | } | 572 | } |
| 573 | } | 573 | } |
| 574 | 574 | ||
| 575 | if ((s->wbio != wbio) && (s->rbio != s->wbio)) | 575 | if (s->rbio != rbio && s->rbio != s->wbio) |
| 576 | BIO_free_all(s->wbio); | ||
| 577 | if (s->rbio != rbio) | ||
| 578 | BIO_free_all(s->rbio); | 576 | BIO_free_all(s->rbio); |
| 577 | if (s->wbio != wbio) | ||
| 578 | BIO_free_all(s->wbio); | ||
| 579 | s->rbio = rbio; | 579 | s->rbio = rbio; |
| 580 | s->wbio = wbio; | 580 | s->wbio = wbio; |
| 581 | } | 581 | } |
