//
// sub_100179420 from 0x100179420 to 0x100179479 (89 bytes)
//
// 1 xrefs:
// > sub_1001793C0 @ 0x1001793c4
//
// 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
//
FILE *__fastcall sub_100179420(__int64 a1, const char *a2, unsigned int a3)
{
char v3; // cl
const char *v4; // rax
int v5; // edx
v3 = 1;
if ( (a3 & 3) == 1 )
{
v4 = "rb";
}
else if ( (a3 & 4) != 0 )
{
v4 = "r+b";
}
else
{
v4 = nullptr;
v5 = (a3 >> 3) & 1;
if ( v5 )
v4 = "wb";
v3 = v5;
}
if ( (a2 == nullptr) | (unsigned __int8)v3 ^ 1 )
return nullptr;
else
return fopen(a2, v4);
}