//
// lws_server_get_canonical_hostname from 0xbc3ee0 to 0xbc3f24 (68 bytes)
//
// 2 xrefs:
// > lws_create_context @ 0xbbf6d8
// > ??> @ 0x4b318
//
// 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 lws_server_get_canonical_hostname(__int64 result, __int64 a2)
{
const char *v2; // [xsp+18h] [xbp+18h]
if ( (*(_DWORD *)(a2 + 100) & 4) == 0 )
{
v2 = (const char *)(result + 168);
gethostname((char *)(result + 168), 0x7Fu);
return lws_log(4, " canonical_hostname = %s\n", v2);
}
return result;
}