/[mailutils]/mailutils/imap4d/append.c
ViewVC logotype

Diff of /mailutils/imap4d/append.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.10 by gray, Mon Aug 5 08:19:00 2002 UTC revision 1.11 by gray, Mon Aug 26 17:06:32 2002 UTC
# Line 26  imap4d_append (struct imap4d_command *co Line 26  imap4d_append (struct imap4d_command *co
26    int flags = 0;    int flags = 0;
27    mailbox_t dest_mbox = NULL;    mailbox_t dest_mbox = NULL;
28    int status;    int status;
29      
30    mboxname = util_getword (arg, &sp);    mboxname = util_getword (arg, &sp);
31    if (!mboxname)    if (!mboxname)
32      return util_finish (command, RESP_BAD, "Too few arguments");      return util_finish (command, RESP_BAD, "Too few arguments");
33    
34    if (*sp == '(' && util_parse_attributes (sp+1, &sp, &flags))    if (*sp == '(' && util_parse_attributes (sp+1, &sp, &flags))
35      return util_finish (command, RESP_BAD, "Missing closing parenthesis");      return util_finish (command, RESP_BAD, "Missing closing parenthesis");
36      
37    mboxname = namespace_getfullpath (mboxname, "/");    mboxname = namespace_getfullpath (mboxname, "/");
38    if (!mboxname)    if (!mboxname)
39      return util_finish (command, RESP_NO, "Couldn't open mailbox");      return util_finish (command, RESP_NO, "Couldn't open mailbox");
# Line 69  imap4d_append0 (mailbox_t mbox, int flag Line 69  imap4d_append0 (mailbox_t mbox, int flag
69    struct tm *tm;    struct tm *tm;
70    time_t t;    time_t t;
71    char date[80];    char date[80];
72      
73    if (mailbox_create (&tmp, "/dev/null"))    if (mailbox_create (&tmp, "/dev/null"))
74      return 1;      return 1;
75    if (mailbox_open (tmp, MU_STREAM_READ) != 0)    if (mailbox_open (tmp, MU_STREAM_READ) != 0)
# Line 82  imap4d_append0 (mailbox_t mbox, int flag Line 82  imap4d_append0 (mailbox_t mbox, int flag
82        return 1;        return 1;
83      }      }
84    
85      while (*text && isspace (*text))
86        text++;
87    
88    /* If a date_time is specified, the internal date SHOULD be set in the    /* If a date_time is specified, the internal date SHOULD be set in the
89       resulting message; otherwise, the internal date of the resulting       resulting message; otherwise, the internal date of the resulting
90       message is set to the current date and time by default. */       message is set to the current date and time by default. */
# Line 126  imap4d_append0 (mailbox_t mbox, int flag Line 129  imap4d_append0 (mailbox_t mbox, int flag
129    return rc;    return rc;
130  }  }
131    
     

Legend:
Removed from v.1.10  
changed lines
  Added in v.1.11

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26