[libpng16] Initialized btoa[] in pngstest.c; stop memory leak in png_handle_eXIf()

when returning with an error.
This commit is contained in:
Glenn Randers-Pehrson
2017-08-01 15:24:21 -05:00
parent 4aad3c0eb0
commit bc68c41d5f
4 changed files with 12 additions and 1 deletions

View File

@@ -2039,7 +2039,10 @@ png_handle_eXIf(png_structrp png_ptr, png_inforp info_ptr, png_uint_32 length)
}
if (png_crc_finish(png_ptr, 0) != 0)
{
png_free(png_ptr, eXIf_buf);
return;
}
png_set_eXIf_1(png_ptr, info_ptr, length, eXIf_buf);