//
// TIFFRGBAImageEnd from 0x8d9980 to 0x8d9b38 (440 bytes)
//
// 4 xrefs:
// > TIFFReadRGBAImageOriented @ 0x8da79c
// > TIFFReadRGBAStrip @ 0x8e6868
// > TIFFReadRGBATile @ 0x8e6b40
// > ??> @ 0x6b42c
//
// 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:07 +0000
//
int __fastcall TIFFRGBAImageEnd(int result)
{
_DWORD *v1; // [sp+4h] [bp-8h]
v1 = (_DWORD *)result;
if ( *(_DWORD *)(result + 56) )
{
result = TIFFfree(*(_DWORD *)(result + 56));
v1[14] = 0;
}
if ( v1[15] )
{
result = TIFFfree(v1[15]);
v1[15] = 0;
}
if ( v1[16] )
{
result = TIFFfree(v1[16]);
v1[16] = 0;
}
if ( v1[17] )
{
result = TIFFfree(v1[17]);
v1[17] = 0;
}
if ( v1[18] )
{
result = TIFFfree(v1[18]);
v1[18] = 0;
}
if ( v1[19] )
{
result = TIFFfree(v1[19]);
v1[19] = 0;
}
if ( v1[20] )
{
result = TIFFfree(v1[20]);
v1[20] = 0;
}
if ( v1[9] )
{
TIFFfree(v1[9]);
TIFFfree(v1[10]);
result = TIFFfree(v1[11]);
v1[11] = 0;
v1[10] = v1[11];
v1[9] = v1[10];
}
return result;
}