[pango: 1/2] Fix build failure in C89 mode
- From: Khaled Hosny <khaledh src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango: 1/2] Fix build failure in C89 mode
- Date: Sat, 4 Aug 2018 20:12:52 +0000 (UTC)
commit 3d04cc2bbdce0a8b561d0e19255309f8d470816e
Author: Ryan Schmidt <git ryandesign com>
Date: Sat Aug 4 11:57:31 2018 -0500
Fix build failure in C89 mode
Fixes build error with default compilers on Mac OS X 10.6 and earlier:
pangocoretext-fontmap.c: In function ‘pango_core_text_fontset_new’:
pangocoretext-fontmap.c:1563: error: ‘for’ loop initial declaration used outside C99 mode
pango/pangocoretext-fontmap.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/pango/pangocoretext-fontmap.c b/pango/pangocoretext-fontmap.c
index cb3f6ff0..6fc8a279 100644
--- a/pango/pangocoretext-fontmap.c
+++ b/pango/pangocoretext-fontmap.c
@@ -1555,12 +1555,13 @@ pango_core_text_fontset_new (PangoCoreTextFontsetKey *key,
const gchar *family;
gchar *name;
GPtrArray *fonts;
+ int i;
fonts = g_ptr_array_new ();
family = pango_font_description_get_family (description);
family_names = g_strsplit (family ? family : "", ",", -1);
- for (int i = 0; family_names[i]; ++i)
+ for (i = 0; family_names[i]; ++i)
{
name = g_utf8_casefold (family_names[i], -1);
font_family = g_hash_table_lookup (key->fontmap->families, name);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]