diff options
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/local/camel-mbox-folder.c | 3 | ||||
-rw-r--r-- | camel/providers/local/camel-mbox-summary.c | 8 |
2 files changed, 4 insertions, 7 deletions
diff --git a/camel/providers/local/camel-mbox-folder.c b/camel/providers/local/camel-mbox-folder.c index d65ad54c01..cfffbf7c16 100644 --- a/camel/providers/local/camel-mbox-folder.c +++ b/camel/providers/local/camel-mbox-folder.c @@ -186,6 +186,9 @@ mbox_append_message(CamelFolder *folder, CamelMimeMessage * message, const Camel if (camel_exception_is_set(ex)) goto fail; + /* and we need to set the frompos explicitly */ + ((CamelMboxMessageInfo *)mi)->frompos = mbs->folder_size?mbs->folder_size+1:0; + d(printf("Appending message: uid is %s\n", mi->uid)); output_stream = camel_stream_fs_new_with_name(lf->folder_path, O_WRONLY|O_APPEND, 0600); diff --git a/camel/providers/local/camel-mbox-summary.c b/camel/providers/local/camel-mbox-summary.c index 32bf411fc6..adff872cc4 100644 --- a/camel/providers/local/camel-mbox-summary.c +++ b/camel/providers/local/camel-mbox-summary.c @@ -587,13 +587,7 @@ mbox_summary_sync(CamelLocalSummary *cls, gboolean expunge, CamelFolderChangeInf char *fromline; /* make sure we're in sync, after this point we at least have a complete list of id's */ - count = camel_folder_summary_count (s); - if (count > 0) { - CamelMessageInfo *mi = camel_folder_summary_index(s, count - 1); - summary_update(mbs, mi->content->endpos, changeinfo, ex); - } else { - summary_update(mbs, 0, changeinfo, ex); - } + summary_update(mbs, mbs->folder_size, changeinfo, ex); if (camel_exception_is_set(ex)) return -1; |