diff --git a/gtk/gtkgrid.c b/gtk/gtkgrid.c index 7aaf8ef818..3557c16949 100644 --- a/gtk/gtkgrid.c +++ b/gtk/gtkgrid.c @@ -439,9 +439,11 @@ gtk_grid_forall (GtkContainer *container, GtkGridChild *child; GList *list; - for (list = priv->children; list; list = list->next) + list = priv->children; + while (list) { child = list->data; + list = list->next; (* callback) (child->widget, callback_data); }