From 2ba62aebceadd299910927c3caa923f8644c4f9f Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Tue, 11 Jul 2023 17:59:13 +1000 Subject: [PATCH] Clear OpenSSL errors on engine errors --- lib/dns/openssl_link.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/dns/openssl_link.c b/lib/dns/openssl_link.c index 005e7832d3..c361c3083b 100644 --- a/lib/dns/openssl_link.c +++ b/lib/dns/openssl_link.c @@ -110,6 +110,7 @@ cleanup_rm: if (global_engine != NULL) { ENGINE_free(global_engine); } + ERR_clear_error(); global_engine = NULL; #endif /* if !defined(OPENSSL_NO_ENGINE) && OPENSSL_API_LEVEL < 30000 */ return (DST_R_NOENGINE);