mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-19 09:50:06 +00:00
Bug 547680 – fontconfig monitoring can crash apps
2008-08-15 Behdad Esfahbod <behdad@gnome.org> Bug 547680 – fontconfig monitoring can crash apps * gtk/gtksettings.c (settings_update_fontconfig): Clear pango cache before recreating fontconfig config. svn path=/trunk/; revision=21134
This commit is contained in:
parent
e8442a52aa
commit
a7f6e2c8fb
@ -1,3 +1,10 @@
|
||||
2008-08-15 Behdad Esfahbod <behdad@gnome.org>
|
||||
|
||||
Bug 547680 – fontconfig monitoring can crash apps
|
||||
|
||||
* gtk/gtksettings.c (settings_update_fontconfig): Clear pango cache
|
||||
before recreating fontconfig config.
|
||||
|
||||
2008-08-15 Sven Herzberg <sven@imendio.com>
|
||||
|
||||
Use the g_test_*() API for this test
|
||||
|
@ -2090,7 +2090,7 @@ settings_update_fontconfig (GtkSettings *settings)
|
||||
static guint last_update_timestamp;
|
||||
static gboolean last_update_needed;
|
||||
|
||||
gint timestamp;
|
||||
guint timestamp;
|
||||
|
||||
g_object_get (settings,
|
||||
"gtk-fontconfig-timestamp", ×tamp,
|
||||
@ -2105,11 +2105,12 @@ settings_update_fontconfig (GtkSettings *settings)
|
||||
PangoFontMap *fontmap = pango_cairo_font_map_get_default ();
|
||||
gboolean update_needed = FALSE;
|
||||
|
||||
if (PANGO_IS_FC_FONT_MAP (fontmap) &&
|
||||
!FcConfigUptoDate (NULL) && FcInitReinitialize ())
|
||||
/* bug 547680 */
|
||||
if (PANGO_IS_FC_FONT_MAP (fontmap) && !FcConfigUptoDate (NULL))
|
||||
{
|
||||
update_needed = TRUE;
|
||||
pango_fc_font_map_cache_clear (PANGO_FC_FONT_MAP (fontmap));
|
||||
if (FcInitReinitialize ())
|
||||
update_needed = TRUE;
|
||||
}
|
||||
|
||||
last_update_timestamp = timestamp;
|
||||
|
Loading…
Reference in New Issue
Block a user