summaryrefslogtreecommitdiffstats
path: root/crypto/engine
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2018-08-03 10:20:59 +0200
committerAndy Polyakov <appro@openssl.org>2018-08-07 09:08:46 +0200
commite519d6b563d95d630723784a5737ebe5ef74e4f3 (patch)
tree660492d442f377014bba15efbe14ccee5e5f28c3 /crypto/engine
parentd1f8b74c584d55a3c7f8f88d997ad69b67076c77 (diff)
engine/eng_lib.c: remove redundant #ifdef.
Reviewed-by: Paul Dale <paul.dale@oracle.com> Reviewed-by: Rich Salz <rsalz@openssl.org> (Merged from https://github.com/openssl/openssl/pull/6786)
Diffstat (limited to 'crypto/engine')
-rw-r--r--crypto/engine/eng_lib.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/crypto/engine/eng_lib.c b/crypto/engine/eng_lib.c
index 9028319788..3ef3aae28a 100644
--- a/crypto/engine/eng_lib.c
+++ b/crypto/engine/eng_lib.c
@@ -75,14 +75,10 @@ int engine_free_util(ENGINE *e, int not_locked)
if (e == NULL)
return 1;
-#ifdef HAVE_ATOMICS
- CRYPTO_DOWN_REF(&e->struct_ref, &i, global_engine_lock);
-#else
if (not_locked)
- CRYPTO_atomic_add(&e->struct_ref, -1, &i, global_engine_lock);
+ CRYPTO_DOWN_REF(&e->struct_ref, &i, global_engine_lock);
else
i = --e->struct_ref;
-#endif
engine_ref_debug(e, 0, -1);
if (i > 0)
return 1;