summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2004-06-21 15:32:07 +0000
committerOwen Taylor <otaylor@src.gnome.org>2004-06-21 15:32:07 +0000
commit3d3e0fc8f7aba66ab41abfad152ea42e8fac8b36 (patch)
tree09b1b53c4c3fc096e738aa89c6ca01fede5c1c7f
parenteaf70a1a0807a0b1b7cce348bcda6a90f5a42e6b (diff)
downloadpango-3d3e0fc8f7aba66ab41abfad152ea42e8fac8b36.tar.gz
For cleanliness, unref the fontmap if we get an error from FreeType.
Mon Jun 21 11:29:39 2004 Owen Taylor <otaylor@redhat.com> * pango/pangoft2-fontmap.c (pango_ft2_font_map_new): For cleanliness, unref the fontmap if we get an error from FreeType. (#143524, Morten Welinder) * pango/pangoft2-fontmap.c (pango_ft2_font_map_finalize): Deal with NULL ft2fontmap->library.
-rw-r--r--ChangeLog9
-rw-r--r--ChangeLog.pre-1-109
-rw-r--r--ChangeLog.pre-1-69
-rw-r--r--ChangeLog.pre-1-89
-rw-r--r--pango/pangoft2-fontmap.c4
5 files changed, 39 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 2b67cd94..23bdf548 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+Mon Jun 21 11:29:39 2004 Owen Taylor <otaylor@redhat.com>
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_new):
+ For cleanliness, unref the fontmap if we get an error
+ from FreeType. (#143524, Morten Welinder)
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_finalize):
+ Deal with NULL ft2fontmap->library.
+
Mon Jun 7 2004 Theppitak Karoonboonyanan <thep@linux.thai.net>
* modules/thai/Makefile.am modules/thai/thai-shaper.c
diff --git a/ChangeLog.pre-1-10 b/ChangeLog.pre-1-10
index 2b67cd94..23bdf548 100644
--- a/ChangeLog.pre-1-10
+++ b/ChangeLog.pre-1-10
@@ -1,3 +1,12 @@
+Mon Jun 21 11:29:39 2004 Owen Taylor <otaylor@redhat.com>
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_new):
+ For cleanliness, unref the fontmap if we get an error
+ from FreeType. (#143524, Morten Welinder)
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_finalize):
+ Deal with NULL ft2fontmap->library.
+
Mon Jun 7 2004 Theppitak Karoonboonyanan <thep@linux.thai.net>
* modules/thai/Makefile.am modules/thai/thai-shaper.c
diff --git a/ChangeLog.pre-1-6 b/ChangeLog.pre-1-6
index 2b67cd94..23bdf548 100644
--- a/ChangeLog.pre-1-6
+++ b/ChangeLog.pre-1-6
@@ -1,3 +1,12 @@
+Mon Jun 21 11:29:39 2004 Owen Taylor <otaylor@redhat.com>
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_new):
+ For cleanliness, unref the fontmap if we get an error
+ from FreeType. (#143524, Morten Welinder)
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_finalize):
+ Deal with NULL ft2fontmap->library.
+
Mon Jun 7 2004 Theppitak Karoonboonyanan <thep@linux.thai.net>
* modules/thai/Makefile.am modules/thai/thai-shaper.c
diff --git a/ChangeLog.pre-1-8 b/ChangeLog.pre-1-8
index 2b67cd94..23bdf548 100644
--- a/ChangeLog.pre-1-8
+++ b/ChangeLog.pre-1-8
@@ -1,3 +1,12 @@
+Mon Jun 21 11:29:39 2004 Owen Taylor <otaylor@redhat.com>
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_new):
+ For cleanliness, unref the fontmap if we get an error
+ from FreeType. (#143524, Morten Welinder)
+
+ * pango/pangoft2-fontmap.c (pango_ft2_font_map_finalize):
+ Deal with NULL ft2fontmap->library.
+
Mon Jun 7 2004 Theppitak Karoonboonyanan <thep@linux.thai.net>
* modules/thai/Makefile.am modules/thai/thai-shaper.c
diff --git a/pango/pangoft2-fontmap.c b/pango/pangoft2-fontmap.c
index 3460eee8..6bc1936c 100644
--- a/pango/pangoft2-fontmap.c
+++ b/pango/pangoft2-fontmap.c
@@ -136,7 +136,8 @@ pango_ft2_font_map_finalize (GObject *object)
if (ft2fontmap->substitute_destroy)
ft2fontmap->substitute_destroy (ft2fontmap->substitute_data);
- FT_Done_FreeType (ft2fontmap->library);
+ if (ft2fontmap->library)
+ FT_Done_FreeType (ft2fontmap->library);
parent_class->finalize (object);
}
@@ -171,6 +172,7 @@ pango_ft2_font_map_new (void)
{
g_warning ("Error from FT_Init_FreeType: %s",
_pango_ft2_ft_strerror (error));
+ g_object_unref (ft2fontmap);
return NULL;
}