diff options
author | Matt Caswell <matt@openssl.org> | 2017-12-04 16:54:59 +0000 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2017-12-08 16:42:02 +0000 |
commit | 921d84a0ad2e70ad91b6e1b06573e97162387f8a (patch) | |
tree | d03290f4271fe08a15a25e13e193124e48c80599 /ssl/record/rec_layer_s3.c | |
parent | 5591a6132ea210b89813d18a852ec2f28b5e2486 (diff) |
Convert the remaining functions in the record layer to use SSLfatal()
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4841)
Diffstat (limited to 'ssl/record/rec_layer_s3.c')
-rw-r--r-- | ssl/record/rec_layer_s3.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/ssl/record/rec_layer_s3.c b/ssl/record/rec_layer_s3.c index 7f35cb897a..5f01b04139 100644 --- a/ssl/record/rec_layer_s3.c +++ b/ssl/record/rec_layer_s3.c @@ -983,14 +983,18 @@ int do_ssl3_write(SSL *s, int type, const unsigned char *buf, * send early data - so we need to use the tls13enc function. */ if (tls13_enc(s, wr, numpipes, 1) < 1) { - SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_DO_SSL3_WRITE, - ERR_R_INTERNAL_ERROR); + if (!ossl_statem_in_error(s)) { + SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_DO_SSL3_WRITE, + ERR_R_INTERNAL_ERROR); + } goto err; } } else { if (s->method->ssl3_enc->enc(s, wr, numpipes, 1) < 1) { - SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_DO_SSL3_WRITE, - ERR_R_INTERNAL_ERROR); + if (!ossl_statem_in_error(s)) { + SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_DO_SSL3_WRITE, + ERR_R_INTERNAL_ERROR); + } goto err; } } |