//
// sub_8D5BCC from 0x8d5bcc to 0x8d5c78 (172 bytes)
//
// 3 xrefs:
// > sub_8D66B4 @ 0x8d68e4
// > sub_8D66B4 @ 0x8d68e8
// > ??> @ 0x8d6998
//
// 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 12:04:06 +0000
//
int __fastcall sub_8D5BCC(_DWORD *a1)
{
_BYTE *v1; // r3
int v4; // [sp+Ch] [bp-8h]
v4 = a1[144];
if ( *(_DWORD *)(v4 + 52) != 8 )
{
if ( a1[152] >= a1[148] )
TIFFFlushData1(a1);
v1 = (_BYTE *)a1[151];
*v1 = *(_DWORD *)(v4 + 48);
a1[151] = v1 + 1;
++a1[152];
*(_DWORD *)(v4 + 48) = 0;
*(_DWORD *)(v4 + 52) = 8;
}
return 1;
}