0.9.6claws7
authorChristoph Hohmann <reboot@gmx.ch>
Sun, 5 Oct 2003 15:52:02 +0000 (15:52 +0000)
committerChristoph Hohmann <reboot@gmx.ch>
Sun, 5 Oct 2003 15:52:02 +0000 (15:52 +0000)
* src/summaryview.c
        don't use flags to check if a message is in a news folder

(closes Bug 282 clicking on folder with copied Messages from News
 immediately after having copied them crashes Sylpheed-Claws)

ChangeLog.claws
configure.ac
src/summaryview.c

index 83ee2db..9bedd54 100644 (file)
@@ -1,3 +1,11 @@
+2003-10-05 [christoph] 0.9.6claws7
+
+       * src/summaryview.c
+               don't use flags to check if a message is in a news folder
+
+       (closes Bug 282 clicking on folder with copied Messages from News
+        immediately after having copied them crashes Sylpheed-Claws)
+
 2003-10-05 [christoph] 0.9.6claws6
 
        * src/Makefile.am
index 89b2c4e..cb46072 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=9
 MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=6
+EXTRA_VERSION=7
 if test $EXTRA_VERSION -eq 0; then
     VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${MICRO_VERSION}claws
 else
index ac2fbda..11a8590 100644 (file)
@@ -1876,7 +1876,8 @@ static void summary_set_marks_func(GtkCTree *ctree, GtkCTreeNode *node,
 
        msginfo = gtk_ctree_node_get_row_data(ctree, node);
 
-       if (MSG_IS_NEWS(msginfo->flags))
+       if (msginfo->folder && msginfo->folder->folder &&
+           msginfo->folder->folder->klass->type == F_NEWS)
                news_flag_crosspost(msginfo);
 
        if (MSG_IS_UNREAD(msginfo->flags) && !MSG_IS_IGNORE_THREAD(msginfo->flags)
@@ -5005,9 +5006,15 @@ static void news_flag_crosspost(MsgInfo *msginfo)
        GString *line;
        gpointer key;
        gpointer value;
-       Folder *mff = msginfo->folder->folder;
+       Folder *mff;
 
-       if (mff->account->mark_crosspost_read && MSG_IS_NEWS(msginfo->flags)) {
+       g_return_if_fail(msginfo != NULL);
+       g_return_if_fail(msginfo->folder != NULL);
+       g_return_if_fail(msginfo->folder->folder != NULL);
+       mff = msginfo->folder->folder;
+       g_return_if_fail(mff->klass->type != F_NEWS);
+
+       if (mff->account->mark_crosspost_read) {
                line = g_string_sized_new(128);
                g_string_sprintf(line, "%s:%d", msginfo->folder->path, msginfo->msgnum);
                debug_print("nfcp: checking <%s>", line->str);