//
// sub_100701EC0 from 0x100701ec0 to 0x100701f88 (200 bytes)
//
// 1 xrefs:
// > ??> @ 0x1009e91f8
//
// This function is hookable on this platform (idp: arm, 32 bit: False, 64 bit: True!
//
// 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 11:12:49 +0000
//
ssize_t __fastcall sub_100701EC0(__int64 a1, void *a2, int a3)
{
ssize_t v6; // x20
int v8; // w8
if ( !a2 )
return 0;
*__error() = 0;
v6 = read(*(_DWORD *)(a1 + 40), a2, a3);
sub_100700768(a1, 15);
if ( (int)v6 <= 0 && (unsigned int)(v6 + 1) <= 1 )
{
v8 = *__error();
if ( v8 > 56 )
{
if ( v8 == 57 || v8 == 100 )
LABEL_16:
sub_100700784(a1, 9);
}
else if ( (unsigned int)v8 <= 0x25 && ((1LL << v8) & 0x3800000010LL) != 0 )
{
goto LABEL_16;
}
}
return v6;
}