//
// std::__ndk1::basic_ostream>::sentry::sentry from 0x509c00 to 0x509c26 (38 bytes)
//
// 4 xrefs:
// > std::__ndk1::basic_ostream>::operator<< @ 0x509c44
// > std::__ndk1::__put_character_sequence> @ 0x509e54
// > std::__ndk1::basic_ostream>::operator<< @ 0x80bb02
// > fmt::print @ 0x81d99e
//
// This function is hookable on this platform (idp: arm, 32 bit: True, 64 bit: False!
//
// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA
// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings
// Generated at Fri, 27 Nov 2026 11:51:26 +0000
//
// Alternative name is '_ZNSt6__ndk113basic_ostreamIcNS_11char_traitsIcEEE6sentryC2ERS3_'
int __fastcall std::ostream::sentry::sentry(int a1, _DWORD *a2)
{
char *v3; // r1
_DWORD *v4; // r0
*(_DWORD *)(a1 + 4) = a2;
*(_BYTE *)a1 = 0;
v3 = (char *)a2 + *(_DWORD *)(*a2 - 12);
if ( !*((_DWORD *)v3 + 4) )
{
v4 = *((_DWORD **)v3 + 18);
if ( v4 )
std::ostream::flush(v4);
*(_BYTE *)a1 = 1;
}
return a1;
}