]> git.wh0rd.org Git - fontconfig.git/commitdiff
Check that a pattern isn't already frozen in FcPatternFreeze
authorRoss Burton <ross@burtonini.com>
Wed, 13 Apr 2005 09:11:52 +0000 (09:11 +0000)
committerRoss Burton <ross@burtonini.com>
Wed, 13 Apr 2005 09:11:52 +0000 (09:11 +0000)
ChangeLog
src/fcpat.c

index 63c44cd9a18fad4202df069430633c928052139f..fbec32ec3ca1ab3330f0a531aae92a98b8d5d051 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-04-13  Ross Burton  <ross@burtonini.com>
+
+       * src/fcpat.c:
+       Check that a pattern isn't already frozen in FcPatternFreeze.
+
 2005-03-31  Ross Burton  <ross@burtonini.com>
 
        * src/fclist.c:
index 32054e12e3780c52f91f90341b75aaf6b50ee7e9..c886c9258e0fa7887f9a592ffc10e9bcc4d8972c 100644 (file)
@@ -538,6 +538,9 @@ FcPatternFreeze (FcPattern *p)
     int                size;
     int                i;
     
+    if (p->ref == FC_REF_CONSTANT)
+       return p;
+
     size = sizeof (FcPattern) + p->num * sizeof (FcPatternElt);
     b = (FcPattern *) malloc (size);
     if (!b)