GUAC-1389: Palette must be freed.

This commit is contained in:
Michael Jumper 2016-03-03 11:06:55 -08:00
parent f7b30414fb
commit e625a7a887

View File

@ -310,6 +310,7 @@ int guac_png_write(guac_socket* socket, guac_stream* stream,
/* Set up PNG writer */
png = png_create_write_struct(PNG_LIBPNG_VER_STRING, NULL, NULL, NULL);
if (!png) {
guac_palette_free(palette);
guac_error = GUAC_STATUS_INTERNAL_ERROR;
guac_error_message = "libpng failed to create write structure";
return -1;