Don't clear errors on failure in CONF_modules_load_file_ex()
authorMatt Caswell <matt@openssl.org>
Wed, 4 Nov 2020 11:31:55 +0000 (11:31 +0000)
committerMatt Caswell <matt@openssl.org>
Fri, 6 Nov 2020 10:34:48 +0000 (10:34 +0000)
commitb8ae4a83de0de38fd382f3981e503f2ab5461c07
treea38fef22dbc431360c7b348454e08a681e05e09a
parent3309c4b716c922172b6a7ae0cef88fad0203886d
Don't clear errors on failure in CONF_modules_load_file_ex()

The call to CONF_modules_load() in CONF_modules_load_file_ex() can
return a negative number to indicate failure. This was incorrectly
being interpreted as "success" and therefore errors were being cleared
incorrectly.

Reviewed-by: Paul Dale <paul.dale@oracle.com>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/13311)
crypto/conf/conf_mod.c