diff options
author | 2011-03-16 22:03:15 +0000 | |
---|---|---|
committer | 2011-03-16 22:03:15 +0000 | |
commit | 376327480b37a6d0a88029f070df991e6add71dc (patch) | |
tree | 8c6cd5519b36155b6a773fd513b5dfc18175ec77 /src/trg-main-window.c | |
parent | fd2ee406559f8732b50e7f5ca5ec0bade12bf83f (diff) |
fix a crash if disconnecting with the graph disabled, disabling tracker/dir filters while disconnected. change possible -NaN for ratio to N/A in general panel.
Diffstat (limited to 'src/trg-main-window.c')
-rw-r--r-- | src/trg-main-window.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/trg-main-window.c b/src/trg-main-window.c index d0ce41a..883faa3 100644 --- a/src/trg-main-window.c +++ b/src/trg-main-window.c @@ -1035,13 +1035,13 @@ static gboolean trg_torrent_tree_view_visible_func(GtkTreeModel * model, GtkTreeIter * iter, gpointer data) { + TrgMainWindowPrivate *priv = TRG_MAIN_WINDOW_GET_PRIVATE(data); + guint flags; gboolean visible; gchar *name; const gchar *filterText; - TrgMainWindowPrivate *priv = TRG_MAIN_WINDOW_GET_PRIVATE(data); - guint32 criteria = trg_state_selector_get_flag(priv->stateSelector); gtk_tree_model_get(model, iter, TORRENT_COLUMN_FLAGS, &flags, -1); @@ -1240,8 +1240,10 @@ void trg_main_window_conn_changed(TrgMainWindow * win, gboolean connected) gtk_list_store_clear(GTK_LIST_STORE(priv->torrentModel)); trg_main_window_torrent_scrub(win); - trg_torrent_graph_set_nothing(priv->graph); trg_state_selector_disconnect(priv->stateSelector); + + if (priv->graphNotebookIndex >= 0) + trg_torrent_graph_set_nothing(priv->graph); } } |