//
// OPENSSL_uni2asc from 0xa3ac2c to 0xa3acc8 (156 bytes)
//
// 2 xrefs:
// > OPENSSL_uni2utf8 @ 0xa3b078
// > ??> @ 0x7f3fc
//
// 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:08:10 +0000
//
_BYTE *__fastcall OPENSSL_uni2asc(int a1, int a2)
{
int v2; // r6
_BYTE *result; // r0
int v6; // r3
if ( (a2 & 1) != 0 )
return nullptr;
v2 = a2 / 2;
if ( !a2 || *(_BYTE *)(a1 + a2 - 1) )
++v2;
result = CRYPTO_malloc((void *)v2, (int)"crypto/pkcs12/p12_utl.c", 53);
if ( !result )
return nullptr;
if ( a2 > 0 )
{
v6 = 0;
do
{
result[v6 >> 1] = *(_BYTE *)(a1 + v6 + 1);
v6 += 2;
}
while ( a2 > v6 );
}
result[v2 - 1] = 0;
return result;
}