//
// ASN1_STRING_clear_free from 0xd6962c to 0xd69684 (88 bytes)
//
// 8 xrefs:
// > sub_D85A44 @ 0xd85ad0
// > sub_D85A44 @ 0xd85b28
// > sub_D85BB0 @ 0xd85c44
// > sub_D85BB0 @ 0xd85cec
// > sub_D888D0 @ 0xd88954
// > sub_D888D0 @ 0xd889a8
// > sub_D88A48 @ 0xd88b0c
// > ??> @ 0x4b960
//
// This function is hookable on this platform!
//
// Using BromaIDA 8.0.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit ba9f177b at Thu Jul 16 22:52:06 2026 from https://github.com/geode-sdk/bindings
//
__int64 __fastcall ASN1_STRING_clear_free(__int64 result)
{
int *v1; // x19
_BYTE *v2; // x0
if ( result )
{
v1 = (int *)result;
v2 = *(_BYTE **)(result + 8);
if ( v2 && (*((_QWORD *)v1 + 2) & 0x10) == 0 )
{
OPENSSL_cleanse(v2, *v1);
return ASN1_STRING_free((__int64)v1);
}
else
{
return ASN1_STRING_free((__int64)v1);
}
}
return result;
}