aboutsummaryrefslogtreecommitdiff
path: root/src/summaryview.c
diff options
context:
space:
mode:
authorhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2011-01-17 09:31:26 +0000
committerhiro <hiro@ee746299-78ed-0310-b773-934348b2243d>2011-01-17 09:31:26 +0000
commit1df57b79dcc7c35765a4ffec6f022afe95e49a2f (patch)
tree79b8b96a286b63cad6b1af67d3b5c42ead07e009 /src/summaryview.c
parenta29dd49c84f0ba7ee9dbdb174c4989330426e0e7 (diff)
fixed crash on quick search when folder tree is empty.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2806 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/summaryview.c')
-rw-r--r--src/summaryview.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/summaryview.c b/src/summaryview.c
index 5eeb5444..ab01fe5b 100644
--- a/src/summaryview.c
+++ b/src/summaryview.c
@@ -5497,6 +5497,8 @@ void summary_qsearch_reset(SummaryView *summaryview)
if (!summaryview->on_filter)
return;
+ if (!summaryview->folder_item)
+ return;
g_signal_handlers_block_matched(G_OBJECT(summaryview->treeview),
(GSignalMatchType)G_SIGNAL_MATCH_DATA,
@@ -5564,6 +5566,9 @@ void summary_qsearch(SummaryView *summaryview)
guint selected_msgnum = 0;
guint displayed_msgnum = 0;
+ if (!summaryview->folder_item)
+ return;
+
menuitem = gtk_menu_get_active(GTK_MENU(summaryview->qsearch->menu));
type = GPOINTER_TO_INT
(g_object_get_data(G_OBJECT(menuitem), MENU_VAL_ID));