changeset 91521:e96ff7166c81

(w32font_open_internal): Use xmalloc, xrealloc, xfree.
author Jason Rumney <jasonr@gnu.org>
date Mon, 04 Feb 2008 15:41:52 +0000
parents 1f6833ce07d9
children 26af07115a9d
files src/w32font.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/w32font.c	Mon Feb 04 14:25:13 2008 +0000
+++ b/src/w32font.c	Mon Feb 04 15:41:52 2008 +0000
@@ -689,13 +689,13 @@
     /* We don't know how much space we need for the full name, so start with
        96 bytes and go up in steps of 32.  */
     len = 96;
-    name = malloc (len);
+    name = xmalloc (len);
     while (name && font_unparse_fcname (font_entity, pixel_size, name, len) < 0)
       {
-        char *new = realloc (name, len += 32);
+        char *new = xrealloc (name, len += 32);
 
         if (! new)
-          free (name);
+          xfree (name);
         name = new;
       }
     if (name)