]> code.citadel.org Git - citadel.git/blobdiff - citadel/imap_misc.c
* Use syslog-compatible logging levels in lprintf(); the loglevel chosen
[citadel.git] / citadel / imap_misc.c
index 1c5cc0bce9faf285fb1528508d93f677ba136082..f1b9771841faa61545edab2c42bf4bcb716ebf58 100644 (file)
@@ -36,7 +36,7 @@
 #include "citserver.h"
 #include "support.h"
 #include "config.h"
-#include "dynloader.h"
+#include "serv_extensions.h"
 #include "room_ops.h"
 #include "user_ops.h"
 #include "policy.h"
@@ -68,7 +68,7 @@ int imap_do_copy(char *destination_folder) {
 
        if (IMAP->num_msgs > 0) {
                for (i = 0; i < IMAP->num_msgs; ++i) {
-                       if (IMAP->flags[i] && IMAP_SELECTED) {
+                       if (IMAP->flags[i] & IMAP_SELECTED) {
                                CtdlCopyMsgToRoom(
                                        IMAP->msgids[i], roomname);
                        }
@@ -255,7 +255,7 @@ void imap_append(int num_parms, char *parms[]) {
        }
 
        /* Convert RFC822 newlines (CRLF) to Unix newlines (LF) */
-       lprintf(9, "Converting newline format\n");
+       lprintf(CTDL_DEBUG, "Converting newline format\n");
        for (i=0; i<literal_length; ++i) {
                if (!strncmp(&IMAP->transmitted_message[i], "\r\n", 2)) {
                        strcpy(&IMAP->transmitted_message[i],
@@ -264,7 +264,7 @@ void imap_append(int num_parms, char *parms[]) {
                }
        }
 
-       lprintf(9, "Converting message format\n");
+       lprintf(CTDL_DEBUG, "Converting message format\n");
         msg = convert_internet_message(IMAP->transmitted_message);
        IMAP->transmitted_message = NULL;
        IMAP->transmitted_length = 0;
@@ -281,7 +281,7 @@ void imap_append(int num_parms, char *parms[]) {
         * folder is selected, save its name so we can return there!!!!!)
         */
        if (IMAP->selected) {
-               strcpy(savedroom, CC->quickroom.QRname);
+               strcpy(savedroom, CC->room.QRname);
        }
        usergoto(roomname, 0, 0, &msgs, &new);
 
@@ -293,11 +293,11 @@ void imap_append(int num_parms, char *parms[]) {
         * private mailboxes.
          */
         if (CC->logged_in) {
-          if ( (CC->quickroom.QRflags & QR_MAILBOX) == 0) {
+          if ( (CC->room.QRflags & QR_MAILBOX) == 0) {
                 if (msg->cm_fields['A'] != NULL) phree(msg->cm_fields['A']);
                 if (msg->cm_fields['N'] != NULL) phree(msg->cm_fields['N']);
                 if (msg->cm_fields['H'] != NULL) phree(msg->cm_fields['H']);
-                msg->cm_fields['A'] = strdoop(CC->usersupp.fullname);
+                msg->cm_fields['A'] = strdoop(CC->user.fullname);
                 msg->cm_fields['N'] = strdoop(config.c_nodename);
                 msg->cm_fields['H'] = strdoop(config.c_humannode);
            }