Merge branch 'configdb' of ssh://git.citadel.org/appl/gitroot/citadel
[citadel.git] / citadel / modules / imap / imap_fetch.c
index 6708fbc4ea4a63f2b9d7cec5de10e1017ee1e46b..8fcd6bd813ab6c2bc3055f65cde7dbb176e4d288 100644 (file)
@@ -706,7 +706,7 @@ void imap_fetch_body(long msgnum, ConstStr item, int is_peek) {
        if (Imap->cached_body == NULL) {
                CCC->redirect_buffer = NewStrBufPlain(NULL, SIZ);
                loading_body_now = 1;
-               msg = CtdlFetchMessage(msgnum, (need_body ? 1 : 0));
+               msg = CtdlFetchMessage(msgnum, (need_body ? 1 : 0), 1);
        }
 
        /* Now figure out what the client wants, and get it */
@@ -1081,7 +1081,7 @@ void imap_do_fetch_msg(int seq, citimap_command *Cmd) {
                                msg = NULL;
                        }
                        if (msg == NULL) {
-                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 1);
+                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 1, 1);
                                body_loaded = 1;
                        }
                        imap_fetch_bodystructure(Imap->msgids[seq-1],
@@ -1089,14 +1089,14 @@ void imap_do_fetch_msg(int seq, citimap_command *Cmd) {
                }
                else if (!strcasecmp(Cmd->Params[i].Key, "ENVELOPE")) {
                        if (msg == NULL) {
-                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 0);
+                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 0, 1);
                                body_loaded = 0;
                        }
                        imap_fetch_envelope(msg);
                }
                else if (!strcasecmp(Cmd->Params[i].Key, "INTERNALDATE")) {
                        if (msg == NULL) {
-                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 0);
+                               msg = CtdlFetchMessage(Imap->msgids[seq-1], 0, 1);
                                body_loaded = 0;
                        }
                        imap_fetch_internaldate(msg);