//
// _isatty from 0x18013f864 to 0x18013f8c3 (95 bytes)
//
// 4 xrefs:
// > __acrt_should_use_temporary_buffer @ 0x180138521
// > _write_nolock @ 0x1801403ea
// > ??> @ 0x180203ba8
// > ??> @ 0x180203bb4
//
// 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 __cdecl isatty(int FileHandle)
{
if ( FileHandle == -2 )
{
*errno() = 9;
}
else
{
if ( FileHandle >= 0 && FileHandle < (unsigned int)dword_1801F5560 )
return *(_BYTE *)(qword_1801F5160[(__int64)FileHandle >> 6] + 72LL * (FileHandle & 0x3F) + 56) & 0x40;
*errno() = 9;
invalid_parameter_noinfo();
}
return 0;
}