diff options
author | Behdad Esfahbod <behdad@gnome.org> | 2007-11-21 09:32:35 +0000 |
---|---|---|
committer | Behdad Esfahbod <behdad@src.gnome.org> | 2007-11-21 09:32:35 +0000 |
commit | fb51fed475e15450feeceeecfb7b954a4c6943a7 (patch) | |
tree | 5123f34046703d54e9c87267b4b2ecf4625bc40d /tests | |
parent | 866049c66b9e34ebb602f4da5a71ba999e2751d2 (diff) | |
download | gtk+-fb51fed475e15450feeceeecfb7b954a4c6943a7.tar.gz |
Fix C89 compilation issue. (#467711, The Written Word)
2007-11-21 Behdad Esfahbod <behdad@gnome.org>
* tests/testrichtext.c (setup_buffer): Fix C89 compilation issue.
(#467711, The Written Word)
svn path=/trunk/; revision=19022
Diffstat (limited to 'tests')
-rw-r--r-- | tests/testrichtext.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/testrichtext.c b/tests/testrichtext.c index c8663049da..d59f608b7b 100644 --- a/tests/testrichtext.c +++ b/tests/testrichtext.c @@ -64,12 +64,14 @@ setup_buffer (GtkTextBuffer *buffer) { const guint tlen = strlen (example_text); const guint tcount = 17; - GtkTextTag *tags[tcount]; + GtkTextTag **tags; GtkTextTagTable *ttable = gtk_text_buffer_get_tag_table (buffer); GSList *node, *slist = NULL; GdkAtom atom; guint i; + tags = g_malloc (sizeof (GtkTextTag *) * tcount); + /* cleanup */ gtk_text_buffer_set_text (buffer, "", 0); gtk_text_tag_table_foreach (ttable, text_tag_enqueue, &slist); @@ -104,6 +106,8 @@ setup_buffer (GtkTextBuffer *buffer) atom = gtk_text_buffer_register_deserialize_tagset (buffer, NULL); gtk_text_buffer_deserialize_set_can_create_tags (buffer, atom, TRUE); + g_free (tags); + return atom; } |