//
// ASN1_BIT_STRING_get_bit from 0x85ff3c to 0x85ff94 (88 bytes)
//
// 4 xrefs:
// > sub_855934 @ 0x855aa4
// > sub_855CA0 @ 0x855e18
// > i2v_ASN1_BIT_STRING @ 0x8c420c
// > ??> @ 0x68e6c
//
// 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
//
int *__fastcall ASN1_BIT_STRING_get_bit(int *result, int a2)
{
int v2; // r3
v2 = a2 / 8;
if ( result )
{
if ( v2 >= *result )
{
return nullptr;
}
else
{
result = (int *)result[2];
if ( result )
return (int *)((*((unsigned __int8 *)result + v2) & (1 << (~(_BYTE)a2 & 7))) != 0);
}
}
return result;
}