提交 f16a64d1 编写于 作者: R Rich Salz

Dead code cleanup; remove #if 0 from crypto/engine

Reviewed-by: NRichard Levitte <levitte@openssl.org>
上级 9ccc00ef
...@@ -64,15 +64,6 @@ void ENGINE_load_builtin_engines(void) ...@@ -64,15 +64,6 @@ void ENGINE_load_builtin_engines(void)
{ {
/* Some ENGINEs need this */ /* Some ENGINEs need this */
OPENSSL_cpuid_setup(); OPENSSL_cpuid_setup();
#if 0
/*
* There's no longer any need for an "openssl" ENGINE unless, one day, it
* is the *only* way for standard builtin implementations to be be
* accessed (ie. it would be possible to statically link binaries with
* *no* builtin implementations).
*/
ENGINE_load_openssl();
#endif
#if !defined(OPENSSL_NO_HW) && (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV)) #if !defined(OPENSSL_NO_HW) && (defined(__OpenBSD__) || defined(__FreeBSD__) || defined(HAVE_CRYPTODEV))
ENGINE_load_cryptodev(); ENGINE_load_cryptodev();
#endif #endif
......
...@@ -353,14 +353,6 @@ ENGINE *ENGINE_by_id(const char *id) ...@@ -353,14 +353,6 @@ ENGINE *ENGINE_by_id(const char *id)
} }
} }
CRYPTO_w_unlock(CRYPTO_LOCK_ENGINE); CRYPTO_w_unlock(CRYPTO_LOCK_ENGINE);
#if 0
if (iterator == NULL) {
ENGINEerr(ENGINE_F_ENGINE_BY_ID, ENGINE_R_NO_SUCH_ENGINE);
ERR_add_error_data(2, "id=", id);
}
return iterator;
#else
/* EEK! Experimental code starts */
if (iterator) if (iterator)
return iterator; return iterator;
/* /*
...@@ -390,7 +382,6 @@ ENGINE *ENGINE_by_id(const char *id) ...@@ -390,7 +382,6 @@ ENGINE *ENGINE_by_id(const char *id)
ERR_add_error_data(2, "id=", id); ERR_add_error_data(2, "id=", id);
return NULL; return NULL;
/* EEK! Experimental code ends */ /* EEK! Experimental code ends */
#endif
} }
int ENGINE_up_ref(ENGINE *e) int ENGINE_up_ref(ENGINE *e)
......
...@@ -91,30 +91,6 @@ void ENGINE_register_all_STORE() ...@@ -91,30 +91,6 @@ void ENGINE_register_all_STORE()
ENGINE_register_STORE(e); ENGINE_register_STORE(e);
} }
/* The following two functions are removed because they're useless. */
#if 0
int ENGINE_set_default_STORE(ENGINE *e)
{
if (e->store_meth)
return engine_table_register(&store_table,
engine_unregister_all_STORE, e,
&dummy_nid, 1, 1);
return 1;
}
#endif
#if 0
/*
* Exposed API function to get a functional reference from the implementation
* table (ie. try to get a functional reference from the tabled structural
* references).
*/
ENGINE *ENGINE_get_default_STORE(void)
{
return engine_table_select(&store_table, dummy_nid);
}
#endif
/* Obtains an STORE implementation from an ENGINE functional reference */ /* Obtains an STORE implementation from an ENGINE functional reference */
const STORE_METHOD *ENGINE_get_STORE(const ENGINE *e) const STORE_METHOD *ENGINE_get_STORE(const ENGINE *e)
{ {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册