diff options
author | Brent Cook <bcook@cvs.openbsd.org> | 2015-07-19 00:56:49 +0000 |
---|---|---|
committer | Brent Cook <bcook@cvs.openbsd.org> | 2015-07-19 00:56:49 +0000 |
commit | 87527a27f93e4d7ba3768ff89e565b1af307cb49 (patch) | |
tree | a44d8033a35e6cca481e6e8586bcca8b18ee76a5 | |
parent | 10a2ae8a65ccd0232bfe475d75e4762fafc41d60 (diff) |
abort when ENGINE_remove fails, fix Coverity 21656
ok doug@, beck@
-rw-r--r-- | lib/libssl/src/crypto/engine/eng_list.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/libssl/src/crypto/engine/eng_list.c b/lib/libssl/src/crypto/engine/eng_list.c index 30f09adc736..fc1d16b183e 100644 --- a/lib/libssl/src/crypto/engine/eng_list.c +++ b/lib/libssl/src/crypto/engine/eng_list.c @@ -1,4 +1,4 @@ -/* $OpenBSD: eng_list.c,v 1.20 2015/06/19 06:32:43 bcook Exp $ */ +/* $OpenBSD: eng_list.c,v 1.21 2015/07/19 00:56:48 bcook Exp $ */ /* Written by Geoff Thorpe (geoff@geoffthorpe.net) for the OpenSSL * project 2000. */ @@ -92,11 +92,8 @@ engine_list_cleanup(void) { ENGINE *iterator = engine_list_head; - while (iterator != NULL) { - ENGINE_remove(iterator); + while (iterator != NULL && ENGINE_remove(iterator)) iterator = engine_list_head; - } - return; } /* These static functions starting with a lower case "engine_" always |