diff options
| author | jsing <> | 2020-09-24 18:12:00 +0000 |
|---|---|---|
| committer | jsing <> | 2020-09-24 18:12:00 +0000 |
| commit | 10841ee643f560678ff5ed0276c4da735ec37bdf (patch) | |
| tree | b00661458f11b9cebfbf0036bd7b8ae827375208 /src/lib/libssl/ssl_lib.c | |
| parent | 1328e78055c6ad087ebbec8484862dea13576ef5 (diff) | |
| download | openbsd-10841ee643f560678ff5ed0276c4da735ec37bdf.tar.gz openbsd-10841ee643f560678ff5ed0276c4da735ec37bdf.tar.bz2 openbsd-10841ee643f560678ff5ed0276c4da735ec37bdf.zip | |
Simplify the cleanup of init_buf via a ssl3_release_init_buffer() function.
ok beck@ inoguchi@ tb@
Diffstat (limited to 'src/lib/libssl/ssl_lib.c')
| -rw-r--r-- | src/lib/libssl/ssl_lib.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/lib/libssl/ssl_lib.c b/src/lib/libssl/ssl_lib.c index 65d5614bfb..6e375e1c09 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.233 2020/09/19 10:17:56 tb Exp $ */ | 1 | /* $OpenBSD: ssl_lib.c,v 1.234 2020/09/24 18:12:00 jsing 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 | * |
| @@ -196,8 +196,7 @@ SSL_clear(SSL *s) | |||
| 196 | tls13_ctx_free(s->internal->tls13); | 196 | tls13_ctx_free(s->internal->tls13); |
| 197 | s->internal->tls13 = NULL; | 197 | s->internal->tls13 = NULL; |
| 198 | 198 | ||
| 199 | BUF_MEM_free(s->internal->init_buf); | 199 | ssl3_release_init_buffer(s); |
| 200 | s->internal->init_buf = NULL; | ||
| 201 | 200 | ||
| 202 | ssl_clear_cipher_state(s); | 201 | ssl_clear_cipher_state(s); |
| 203 | 202 | ||
| @@ -531,7 +530,7 @@ SSL_free(SSL *s) | |||
| 531 | 530 | ||
| 532 | tls13_ctx_free(s->internal->tls13); | 531 | tls13_ctx_free(s->internal->tls13); |
| 533 | 532 | ||
| 534 | BUF_MEM_free(s->internal->init_buf); | 533 | ssl3_release_init_buffer(s); |
| 535 | 534 | ||
| 536 | sk_SSL_CIPHER_free(s->cipher_list); | 535 | sk_SSL_CIPHER_free(s->cipher_list); |
| 537 | sk_SSL_CIPHER_free(s->internal->cipher_list_tls13); | 536 | sk_SSL_CIPHER_free(s->internal->cipher_list_tls13); |
