From 1d90d3182f63fdbacc392269eb407eb093ede118 Mon Sep 17 00:00:00 2001 From: Jon Bergli Heier Date: Sat, 8 May 2010 13:34:11 +0200 Subject: Fixed assertion in the tag model when no tags exist. --- tag_model.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tag_model.c b/tag_model.c index 0ba33ef..a292fe1 100644 --- a/tag_model.c +++ b/tag_model.c @@ -211,8 +211,8 @@ static gboolean tag_model_get_iter(GtkTreeModel *tree_model, GtkTreeIter *iter, depth = gtk_tree_path_get_depth(path); n = indices[depth-1]; - //if(n >= tag_model->num_rows || n < 0) - // return FALSE; + if((depth == 1 && n >= tag_model->num_rows) || n < 0) + return FALSE; //record = &g_array_index(tag_model->rows, TagModelRecord, n); record = tag_model_get_record_recursive(tag_model, indices, depth); -- cgit v1.2.3