//
// ENGINE_get_first from 0xa0c42c to 0xa0c4d4 (168 bytes)
//
// 12 xrefs:
// > sub_854AF8 @ 0x854afa
// > ENGINE_register_all_complete @ 0xa0bc64
// > ENGINE_register_all_pkey_asn1_meths @ 0xa0d300
// > ENGINE_register_all_ciphers @ 0xa0d738
// > ENGINE_register_all_DH @ 0xa0d8fc
// > ENGINE_register_all_digests @ 0xa0da4c
// > ENGINE_register_all_DSA @ 0xa0dc10
// > ENGINE_register_all_EC @ 0xa0dd40
// > ENGINE_register_all_pkey_meths @ 0xa0de90
// > ENGINE_register_all_RAND @ 0xa0e0d8
// > ENGINE_register_all_RSA @ 0xa0e208
// > ??> @ 0x6845c
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 12:07:43 +0000
//
int ENGINE_get_first()
{
int v0; // r0
int v1; // r4
if ( CRYPTO_THREAD_run_once(&engine_lock_init, do_engine_lock_init_ossl_) && do_engine_lock_init_ossl_ret_ )
{
CRYPTO_THREAD_write_lock(global_engine_lock);
v0 = global_engine_lock;
v1 = dword_D34110;
if ( dword_D34110 )
++*(_DWORD *)(dword_D34110 + 80);
CRYPTO_THREAD_unlock(v0);
return v1;
}
else
{
ERR_put_error(38, 195, 65, "crypto/engine/eng_list.c", 140);
return 0;
}
}