//
// CRYPTO_realloc from 0xa2312c to 0xa231c0 (148 bytes)
//
// 29 xrefs:
// > SSL_CTX_dane_mtype_set @ 0x9ab224
// > SSL_CTX_dane_mtype_set @ 0x9ab24c
// > SSL_CTX_use_serverinfo @ 0x9b1b2c
// > SSL_CTX_use_serverinfo_file @ 0x9b1e3c
// > SSL_CTX_add_server_custom_ext @ 0x9c2098
// > SSL_CTX_add_client_custom_ext @ 0x9c21f0
// > ASN1_STRING_set @ 0x9d7718
// > sub_9E16AC @ 0x9e17b4
// > sub_9E1868 @ 0x9e2158
// > sub_9E2500 @ 0x9e27d4
// > sub_9E2500 @ 0x9e2a24
// > BUF_MEM_grow @ 0x9ed8e0
// > ERR_add_error_vdata @ 0xa101b4
// > OPENSSL_LH_insert @ 0xa211a8
// > OPENSSL_LH_delete @ 0xa2143c
// > CRYPTO_realloc @ 0xa23160
// > sub_A2C460 @ 0xa2c5fc
// > OPENSSL_sk_insert @ 0xa4d390
// > sub_A6D080 @ 0xa6d2e0
// > sub_A6D080 @ 0xa6d45c
// > sub_A6D080 @ 0xa6d508
// > a2i_ASN1_STRING @ 0xa7bf74
// > ??> @ 0x7548c
// > CRYPTO_realloc @ 0xa2313c
// > CRYPTO_realloc @ 0xa23140
// > CRYPTO_set_mem_functions @ 0xa231fc
// > CRYPTO_get_mem_functions @ 0xa23288
// > ??> @ 0xd1d600
// > ??> @ 0xd25ff0
//
// 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:57 +0000
//
void *__fastcall CRYPTO_realloc(void *a1, void *a2, int a3, int a4)
{
bool v4; // zf
v4 = off_D25FF0 == nullptr;
if ( off_D25FF0 )
v4 = (char *)off_D25FF0 == (char *)CRYPTO_realloc;
if ( !v4 )
return (void *)((int (__fastcall *)(void *, void *, int, int))off_D25FF0)(a1, a2, a3, a4);
if ( !a1 )
return CRYPTO_malloc(a2, a3, a4);
if ( a2 )
{
dword_D25FE4 = 0;
return realloc(a1, (size_t)a2);
}
else
{
CRYPTO_free(a1, a3, a4);
return a2;
}
}