Commit b0ea4586 authored by Bastian Winkler's avatar Bastian Winkler

grid: Fix access to grid->priv member

The priv member should be accessed after the g_return_if_fail test

https://bugzilla.gnome.org/show_bug.cgi?id=677363
parent 4fee1aa2
......@@ -1642,13 +1642,15 @@ void
gtk_grid_insert_row (GtkGrid *grid,
gint position)
{
GtkGridPrivate *priv = grid->priv;
GtkGridPrivate *priv;
GtkGridChild *child;
GList *list;
gint top, height;
g_return_if_fail (GTK_IS_GRID (grid));
priv = grid->priv;
for (list = priv->children; list; list = list->next)
{
child = list->data;
......@@ -1686,13 +1688,15 @@ void
gtk_grid_insert_column (GtkGrid *grid,
gint position)
{
GtkGridPrivate *priv = grid->priv;
GtkGridPrivate *priv;
GtkGridChild *child;
GList *list;
gint left, width;
g_return_if_fail (GTK_IS_GRID (grid));
priv = grid->priv;
for (list = priv->children; list; list = list->next)
{
child = list->data;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment