//
// ENGINE_remove from 0xa0c8cc to 0xa0ca00 (308 bytes)
//
// 2 xrefs:
// > sub_A0CA18 @ 0xa0ca30
// > ??> @ 0x7bfac
//
// 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:44 +0000
//
int __fastcall ENGINE_remove(int a1)
{
int v2; // r3
bool v3; // zf
int v4; // r4
bool v5; // zf
int v6; // r2
int v7; // r1
if ( a1 )
{
CRYPTO_THREAD_write_lock(global_engine_lock);
v2 = dword_D34110;
v3 = a1 == dword_D34110;
if ( a1 != dword_D34110 )
v3 = dword_D34110 == 0;
v4 = dword_D34110;
if ( !v3 )
{
do
{
v4 = *(_DWORD *)(v4 + 96);
v5 = a1 == v4;
if ( a1 != v4 )
v5 = v4 == 0;
}
while ( !v5 );
}
if ( v4 )
{
v6 = *(_DWORD *)(a1 + 96);
if ( v6 )
*(_DWORD *)(v6 + 92) = *(_DWORD *)(a1 + 92);
v7 = *(_DWORD *)(a1 + 92);
if ( v7 )
*(_DWORD *)(v7 + 96) = v6;
if ( a1 == v2 )
dword_D34110 = *(_DWORD *)(a1 + 96);
v4 = 1;
if ( a1 == dword_D34114 )
dword_D34114 = v7;
engine_free_util(a1, 0);
}
else
{
ERR_put_error(38, 121, 105, "crypto/engine/eng_list.c", 117);
ERR_put_error(38, 123, 110, "crypto/engine/eng_list.c", 245);
}
CRYPTO_THREAD_unlock(global_engine_lock);
return v4;
}
else
{
ERR_put_error(38, 123, 67, "crypto/engine/eng_list.c", 240);
return 0;
}
}