//
// sub_B71478 from 0xb71478 to 0xb715dc (356 bytes)
//
// 2 xrefs:
// > sub_B715DC @ 0xb71770
// > sub_B71BAC @ 0xb71ea0
//
// 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
//
char *__fastcall sub_B71478(__int64 a1, __int64 a2, const char *a3, int a4)
{
char *result; // x0
char *v7; // x20
int v8; // w0
char *v9; // x19
int v10; // t1
size_t v11; // x24
_QWORD *v12; // x0
_QWORD *v13; // x21
__int64 v14; // x0
__int64 v15; // x19
result = (char *)sub_B8F880("%s:%d", a3, a4);
v7 = result;
if ( result )
{
v8 = (unsigned __int8)*result;
if ( v8 != 58 && v8 )
{
v9 = v7;
do
{
*v9 = tolower(v8);
v10 = (unsigned __int8)*++v9;
v8 = v10;
}
while ( v10 != 58 && v8 );
}
v11 = strlen(v7);
v12 = off_1231020(1u, 0x18u);
v13 = v12;
if ( v12 )
{
v12[2] = 1;
*v12 = a2;
time(v12 + 1);
if ( !v13[1] )
v13[1] = 1;
v14 = sub_B998CC(*(_QWORD *)(a1 + 80), v7, v11 + 1, v13);
v15 = v14;
if ( v14 )
{
++*(_QWORD *)(v14 + 16);
off_1231008(v7);
return (char *)v15;
}
else
{
off_1231008(v13);
off_1231008(v7);
return nullptr;
}
}
else
{
off_1231008(v7);
return nullptr;
}
}
return result;
}