Mercurial > pidgin.yaz
comparison src/gtkdebug.c @ 11056:9be8ac00f27f
[gaim-migrate @ 13007]
Don't crash when unregistering debug categroies and the debug window is
not open
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 04 Jul 2005 20:03:18 +0000 |
parents | ba506d2e6a8e |
children | a511b77a368b |
comparison
equal
deleted
inserted
replaced
11055:df0241eb602c | 11056:9be8ac00f27f |
---|---|
667 static void | 667 static void |
668 gaim_gtk_debug_unregister_category(const char *category) | 668 gaim_gtk_debug_unregister_category(const char *category) |
669 { | 669 { |
670 GtkTreeModel *model = NULL; | 670 GtkTreeModel *model = NULL; |
671 | 671 |
672 if (debug_win == NULL) | |
673 return; | |
674 | |
672 model = gtk_tree_view_get_model(GTK_TREE_VIEW(debug_win->treeview)); | 675 model = gtk_tree_view_get_model(GTK_TREE_VIEW(debug_win->treeview)); |
673 | 676 |
674 gtk_tree_model_foreach(model, | 677 gtk_tree_model_foreach(model, |
675 (GtkTreeModelForeachFunc)find_and_remove_category, | 678 (GtkTreeModelForeachFunc)find_and_remove_category, |
676 (char *)category); | 679 (char *)category); |