//
// png_read_finish_IDAT from 0x86f3a4 to 0x86f41a (118 bytes)
//
// 2 xrefs:
// > png_read_end @ 0x8673d6
// > png_read_finish_row @ 0x86f4b8
//
// 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:02:56 +0000
//
_DWORD *__fastcall png_read_finish_IDAT(_DWORD *result)
{
_DWORD *v1; // r5
int v2; // r3
v1 = result;
if ( (result[78] & 8) != 0 )
{
if ( result[80] != 1229209940 )
return result;
LABEL_7:
v1[81] = 0;
v1[82] = 0;
v1[80] = 0;
return (_DWORD *)png_crc_finish(v1, v1[127]);
}
result = (_DWORD *)png_read_IDAT_data(result, 0, 0);
v2 = v1[78];
v1[84] = 0;
if ( (v2 & 8) == 0 )
{
v1[78] = v2 | 8;
v1[77] |= 8u;
}
if ( v1[80] == 1229209940 )
goto LABEL_7;
return result;
}