bugfix: don't crash if parent node deleted from thread attracted by subject line
authorAlfons Hoogervorst <alfons@proteus.demon.nl>
Wed, 27 Jun 2001 20:44:28 +0000 (20:44 +0000)
committerAlfons Hoogervorst <alfons@proteus.demon.nl>
Wed, 27 Jun 2001 20:44:28 +0000 (20:44 +0000)
ChangeLog.claws
src/summaryview.c

index 1d85954..9a3fbdc 100644 (file)
@@ -1,10 +1,17 @@
 2001-06-27 [alfons]
 
-               * src/summaryview.c
-               * src/compose.[ch]
-               * src/mainwindow.c
-                       if there are multiple messages selected, allow forwarding
-                       them as attachments.
+       * src/summaryview.c
+               don't crash when removing parent node of messages
+               attracted by subject. this was caused by not deleting
+               the parent node from the subject line hash table.
+
+2001-06-27 [alfons]
+
+       * src/summaryview.c
+       * src/compose.[ch]
+       * src/mainwindow.c
+               if there are multiple messages selected, allow forwarding
+               them as attachments.
 
 2001-06-27 [paul]
 
index fd849fa..501246e 100644 (file)
@@ -2734,6 +2734,13 @@ static void summary_execute_delete_func(GtkCTree *ctree, GtkCTreeNode *node,
                                                msginfo->msgid))
                        g_hash_table_remove(summaryview->msgid_table,
                                            msginfo->msgid);
+
+               if (msginfo->subject && 
+                   node == subject_table_lookup(summaryview->subject_table, 
+                                               msginfo->subject)) {
+                       gchar *s = msginfo->subject + (g_strncasecmp(msginfo->subject, "Re: ", 4) == 0 ? 4 : 0);
+                       g_hash_table_remove(summaryview->subject_table, s);
+               }                       
        }
 }