<<< Date Index >>>     <<< Thread Index >>>

[PATCH] cleanup printf args



I had a couple of patches lying around for weeks and forgot about them.
Sending one patch per mail.

Regards,
Ralf

        * imap/command.c, imap/message.c: Match printf format strings
        with argument. 

Index: imap/command.c
===================================================================
RCS file: /home/roessler/cvs/mutt/imap/command.c,v
retrieving revision 3.9
diff -u -r3.9 command.c
--- imap/command.c      2 Aug 2004 08:03:46 -0000       3.9
+++ imap/command.c      19 Nov 2004 09:54:39 -0000
@@ -395,7 +395,7 @@
 /* cmd_make_sequence: make a tag suitable for starting an IMAP command */
 static void cmd_make_sequence (IMAP_DATA* idata)
 {
-  snprintf (idata->cmd.seq, sizeof (idata->cmd.seq), "a%04d", idata->seqno++);
+  snprintf (idata->cmd.seq, sizeof (idata->cmd.seq), "a%04u", idata->seqno++);
 
   if (idata->seqno > 9999)
     idata->seqno = 0;
Index: imap/message.c
===================================================================
RCS file: /home/roessler/cvs/mutt/imap/message.c,v
retrieving revision 3.11
diff -u -r3.11 message.c
--- imap/message.c      8 Nov 2004 07:30:29 -0000       3.11
+++ imap/message.c      19 Nov 2004 09:54:39 -0000
@@ -263,7 +263,7 @@
    * command handler */
   h->active = 0;
   
-  snprintf (buf, sizeof (buf), "UID FETCH %d %s", HEADER_DATA(h)->uid,
+  snprintf (buf, sizeof (buf), "UID FETCH %u %s", HEADER_DATA(h)->uid,
            (mutt_bit_isset (idata->capabilities, IMAP4REV1) ?
             (option (OPTIMAPPEEK) ? "BODY.PEEK[]" : "BODY[]") :
             "RFC822"));