From 5f96e82865a96afac3936fdf449f1c23689f0fac Mon Sep 17 00:00:00 2001 From: handa Date: Fri, 3 Sep 2004 08:30:17 +0000 Subject: [PATCH] (GSTRING_INSERT): Fix size of reallocating memory. --- src/otfdrive.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/otfdrive.c b/src/otfdrive.c index f7f2034..975e969 100644 --- a/src/otfdrive.c +++ b/src/otfdrive.c @@ -53,8 +53,9 @@ write to the Free Software Foundation, Inc., 59 Temple Place, Suite char *errfmt = "GSTRING%s"; \ \ gstring->size = gstring->used + len; \ - gstring->glyphs = (OTF_Glyph *) realloc (gstring->glyphs, \ - gstring->size); \ + gstring->glyphs \ + = (OTF_Glyph *) realloc (gstring->glyphs, \ + sizeof (OTF_Glyph) * gstring->size); \ if (! gstring->glyphs) \ OTF_ERROR (OTF_ERROR_MEMORY, ""); \ } \ -- 1.7.10.4