]> Pileus Git - ~andy/gtk/commit
Bug 659022 - gtk_tree_model_filter_clear_cache_helper: assertion failed
authorKristian Rietveld <kris@gtk.org>
Mon, 3 Oct 2011 20:38:42 +0000 (22:38 +0200)
committerKristian Rietveld <kris@gtk.org>
Mon, 3 Oct 2011 20:59:40 +0000 (22:59 +0200)
commitbbc1e883a860fab04f230043bffbf3e4c78f66ef
tree054b44fd1bb9cab9c5ab9280bf30844367a9ad7d
parente8323e2abc97156e3c416126686158b393083970
Bug 659022 - gtk_tree_model_filter_clear_cache_helper: assertion failed

This bug is resolved by fixing two things in
gtk_tree_model_filter_row_deleted():

  (1) It is possible for an elt to have elt->visible_siter == NULL, when
  it is deleted.  Only call g_sequence_remove() if this pointer is
  non-NULL.

  (2) For the case len (level->seq) > 1, free the elt->children level
  if non-NULL.  Failing to do this means the level will stick around.
  If this child level was not referenced, it will still have a zero
  ref count on its parent which cannot be removed!

For both bugs unit tests have been added in the preceding commit.
gtk/gtktreemodelfilter.c