//
// sub_10056A5F4 from 0x10056a5f4 to 0x10056a6b8 (196 bytes)
//
// 3 xrefs:
// > sub_10056A3E4 @ 0x10056a53c
// > sub_10056A3E4 @ 0x10056a56c
// > sub_10056AEA0 @ 0x10056af98
//
// 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 sub_10056A5F4(__int64 a1, char *a2, _QWORD *a3)
{
int v6; // w8
const void *v7; // x1
int v8; // w0
v6 = *(unsigned __int8 *)(a1 + 1);
switch ( v6 )
{
case 1:
sub_100562884(a2, 46, "%s", (const char *)(a1 + 2));
*a3 = 0;
return 1;
case 30:
v7 = (const void *)(a1 + 8);
v8 = 30;
break;
case 2:
v7 = (const void *)(a1 + 4);
v8 = 2;
break;
default:
goto LABEL_9;
}
if ( inet_ntop(v8, v7, a2, 0x2Eu) )
{
*a3 = (unsigned __int16)((unsigned __int8)HIBYTE(*(_WORD *)(a1 + 2)) | (unsigned __int16)(*(_WORD *)(a1 + 2) << 8));
return 1;
}
LABEL_9:
*a2 = 0;
*a3 = 0;
return 0;
}