libansilove

Library for converting ANSI, ASCII, and other formats to PNG
Log | Files | Refs | README | LICENSE

commit c55cf0c0b2cfee6dcc18ac38c4a503ff279c0240
parent f41935236f1b29560167e1ac41326c8589969278
Author: Frederic Cambus <fred@statdns.com>
Date:   Fri,  8 Feb 2019 14:09:35 +0100

Also call gdImageDestroy() when generating Retina or DOS aspect ratio output.

Diffstat:
Msrc/output.c | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/output.c b/src/output.c @@ -42,6 +42,7 @@ output(struct ansilove_ctx *ctx, struct ansilove_options *options, gdImageDestroy(im_Source); ctx->png.buffer = gdImagePngPtr(im_DOS, &ctx->png.length); + gdImageDestroy(im_DOS); } else { gdImagePtr im_Retina; @@ -59,6 +60,7 @@ output(struct ansilove_ctx *ctx, struct ansilove_options *options, /* create retina output image */ gdImageDestroy(im_Source); ctx->png.buffer = gdImagePngPtr(im_Retina, &ctx->png.length); + gdImageDestroy(im_Retina); } return 0;