Skip to content

Commit

Permalink
https://github.com/ImageMagick/ImageMagick/issues/782
Browse files Browse the repository at this point in the history
  • Loading branch information
Cristy committed Sep 27, 2017
1 parent 97740cc commit 499a0c0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions MagickCore/annotate.c
Expand Up @@ -1382,14 +1382,15 @@ static MagickBooleanType RenderFreetype(Image *image,const DrawInfo *draw_info,
args.pathname=ConstantString(draw_info->font+1);
face=(FT_Face) NULL;
ft_status=FT_Open_Face(library,&args,(long) draw_info->face,&face);
args.pathname=DestroyString(args.pathname);
if (ft_status != 0)
{
(void) FT_Done_FreeType(library);
(void) ThrowMagickException(exception,GetMagickModule(),TypeError,
"UnableToReadFont","`%s'",draw_info->font);
"UnableToReadFont","`%s'",args.pathname);
args.pathname=DestroyString(args.pathname);
return(MagickFalse);
}
args.pathname=DestroyString(args.pathname);
if ((draw_info->metrics != (char *) NULL) &&
(IsPathAccessible(draw_info->metrics) != MagickFalse))
(void) FT_Attach_File(face,draw_info->metrics);
Expand Down

0 comments on commit 499a0c0

Please sign in to comment.