//
// png_write_chunk_end from 0xbeb3d4 to 0xbeb41c (72 bytes)
//
// 28 xrefs:
// > png_write_chunk @ 0xbeb4f0
// > png_write_IHDR @ 0xbeb74c
// > png_write_PLTE @ 0xbeba10
// > png_compress_IDAT @ 0xbebc1c
// > png_compress_IDAT @ 0xbebdd4
// > png_write_IEND @ 0xbebfcc
// > png_write_gAMA_fixed @ 0xbec0b8
// > png_write_sRGB @ 0xbec1a8
// > png_write_iCCP @ 0xbec374
// > png_write_sPLT @ 0xbec5cc
// > png_write_sBIT @ 0xbec738
// > png_write_cHRM_fixed @ 0xbec8d0
// > png_write_tRNS @ 0xbeca4c
// > png_write_tRNS @ 0xbecad8
// > png_write_tRNS @ 0xbecb9c
// > png_write_bKGD @ 0xbeccb0
// > png_write_bKGD @ 0xbecdb8
// > png_write_bKGD @ 0xbece90
// > png_write_hIST @ 0xbecf84
// > png_write_tEXt @ 0xbed0c8
// > png_write_zTXt @ 0xbed2b8
// > png_write_iTXt @ 0xbed524
// > png_write_oFFs @ 0xbed864
// > png_write_pCAL @ 0xbeda68
// > png_write_sCAL_s @ 0xbedc8c
// > png_write_pHYs @ 0xbeddbc
// > png_write_tIME @ 0xbedf10
// > ??> @ 0xb8c38
//
// 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 png_write_chunk_end(__int64 result)
{
__int64 v1; // x19
int v2; // w1
char v3; // [xsp+28h] [xbp+28h] BYREF
if ( result )
{
v1 = result;
v2 = *(_DWORD *)(result + 660);
*(_DWORD *)(result + 1252) = 130;
png_save_uint_32(&v3, v2);
return png_write_data(v1);
}
return result;
}