atoi(pathbasename));
g_free(pathbasename);
oldperm_flags = msginfo->flags.perm_flags;
+ procmsg_msginfo_free(&msginfo);
ritem->items = g_slist_remove(ritem->items, old_item);
if (g_unlink(ctx->path) != 0) {
* doesn't want to see it unread because of the change. */
if (dif != EXISTS_NEW) {
if (!(oldperm_flags & MSG_UNREAD) && (ritem->silent_update == 2
- || (ritem->silent_update == 1 && dif == EXISTS_CHANGED_TEXTONLY)))
- procmsg_msginfo_unset_flags(
- folder_item_get_msginfo((FolderItem *)ritem, d), MSG_NEW | MSG_UNREAD, 0);
+ || (ritem->silent_update == 1 && dif == EXISTS_CHANGED_TEXTONLY))) {
+ msginfo = folder_item_get_msginfo((FolderItem *)ritem, d);
+ procmsg_msginfo_unset_flags(msginfo, MSG_NEW | MSG_UNREAD, 0);
+ procmsg_msginfo_free(&msginfo);
+ }
}
debug_print("RSSyl: folder_item_add_msg(): %d\n", d);