From ec42b075248c69aad25efc0a6ce12357aef13ef2 Mon Sep 17 00:00:00 2001 From: Cristy Date: Sat, 10 Dec 2016 19:49:44 -0500 Subject: [PATCH] Fix a small memory leak --- coders/caption.c | 2 +- coders/label.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/coders/caption.c b/coders/caption.c index b0241ac54..0fe6fe1d1 100644 --- a/coders/caption.c +++ b/coders/caption.c @@ -275,7 +275,7 @@ static Image *ReadCAPTIONImage(const ImageInfo *image_info, draw_info->direction == RightToLeftDirection ? image->columns- metrics.bounds.x2 : -metrics.bounds.x1,0.0),draw_info->gravity == UndefinedGravity ? metrics.ascent : 0.0); - draw_info->geometry=AcquireString(geometry); + (void) CloneString(&draw_info->geometry,geometry); status=AnnotateImage(image,draw_info,exception); if (image_info->pointsize == 0.0) { diff --git a/coders/label.c b/coders/label.c index da25f1c49..dac96f3ac 100644 --- a/coders/label.c +++ b/coders/label.c @@ -234,7 +234,7 @@ static Image *ReadLABELImage(const ImageInfo *image_info, draw_info->direction == RightToLeftDirection ? image->columns- metrics.bounds.x2 : 0.0,draw_info->gravity == UndefinedGravity ? metrics.ascent : 0.0); - draw_info->geometry=AcquireString(geometry); + (void) CloneString(&draw_info->geometry,geometry); status=AnnotateImage(image,draw_info,exception); if (image_info->pointsize == 0.0) { -- 2.40.0