//
// EC_POINT_point2buf from 0xa02124 to 0xa021c8 (164 bytes)
//
// 5 xrefs:
// > EC_GROUP_get_ecparameters @ 0x9fabe8
// > EC_KEY_key2buf @ 0x9fe324
// > EC_POINT_point2bn @ 0xaa004c
// > EC_POINT_point2hex @ 0xaa01ec
// > ??> @ 0x7ae8c
//
// 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:38 +0000
//
int __fastcall EC_POINT_point2buf(int a1, _DWORD *a2, int a3, int *a4)
{
int v7; // r0
int result; // r0
int v9; // r9
v7 = EC_POINT_point2oct(a1, a2);
if ( !v7 )
return 0;
v9 = CRYPTO_malloc(v7, "crypto/ec/ec_oct.c", 155);
if ( !v9 )
return 0;
result = EC_POINT_point2oct(a1, a2);
if ( result )
{
*a4 = v9;
}
else
{
CRYPTO_free(v9, "crypto/ec/ec_oct.c", 160);
return 0;
}
return result;
}