From ff988500c2f39ae61b2836167b6e0e7b2021220c Mon Sep 17 00:00:00 2001 From: Rich Salz Date: Wed, 31 Jul 2019 15:24:20 -0400 Subject: Replace FUNCerr with ERR_raise_data Reviewed-by: Paul Dale Reviewed-by: Richard Levitte (Merged from https://github.com/openssl/openssl/pull/9496) --- ssl/ssl_cert.c | 5 +++-- ssl/ssl_lib.c | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'ssl') diff --git a/ssl/ssl_cert.c b/ssl/ssl_cert.c index 3afa5e5387..f902091968 100644 --- a/ssl/ssl_cert.c +++ b/ssl/ssl_cert.c @@ -766,8 +766,9 @@ int SSL_add_dir_cert_subjects_to_stack(STACK_OF(X509_NAME) *stack, } if (errno) { - FUNCerr("readdir", get_last_sys_error()); - ERR_add_error_data(3, "OPENSSL_DIR_read(&ctx, '", dir, "')"); + ERR_raise_data(ERR_LIB_SYS, get_last_sys_error(), + "calling OPENSSL_dir_read(%s)", + dir); SSLerr(SSL_F_SSL_ADD_DIR_CERT_SUBJECTS_TO_STACK, ERR_R_SYS_LIB); goto err; } diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index a943414255..0d40ecaec9 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -2075,7 +2075,8 @@ ossl_ssize_t SSL_sendfile(SSL *s, int fd, off_t offset, size_t size, int flags) else #endif #ifdef OPENSSL_NO_KTLS - FUNCerr("sendfile", get_last_sys_error()); + ERR_raise_data(ERR_LIB_SYS, get_last_sys_error(), + "calling sendfile()"); #else SSLerr(SSL_F_SSL_SENDFILE, SSL_R_UNINITIALIZED); #endif -- cgit v1.2.3