]> granicus.if.org Git - curl/commitdiff
imap: Added comments to imap_append()
authorSteve Holme <steve_holme@hotmail.com>
Sun, 3 Mar 2013 16:44:53 +0000 (16:44 +0000)
committerSteve Holme <steve_holme@hotmail.com>
Sun, 3 Mar 2013 16:44:53 +0000 (16:44 +0000)
lib/imap.c

index cf27d6084f36fe0c9a289382ec112ae0a3529be7..503ed6d469f4b74c61aa01bdff2f99c386b8c2a2 100644 (file)
@@ -730,16 +730,18 @@ static CURLcode imap_append(struct connectdata *conn)
   struct IMAP *imap = conn->data->state.proto.imap;
   char *mailbox;
 
+  /* Check we know the size of the upload */
   if(conn->data->set.infilesize < 0) {
     failf(conn->data, "Cannot APPEND with unknown input file size\n");
     return CURLE_UPLOAD_FAILED;
   }
 
+  /* Make sure the mailbox is in the correct atom format */
   mailbox = imap_atom(imap->mailbox);
-
   if(!mailbox)
     return CURLE_OUT_OF_MEMORY;
 
+  /* Send the APPEND command */
   result = imap_sendf(conn, "APPEND %s (\\Seen) {%" FORMAT_OFF_T "}",
                       mailbox, conn->data->set.infilesize);