diff options
author | Yang Tse <yangsita@gmail.com> | 2013-07-23 15:59:07 +0200 |
---|---|---|
committer | Yang Tse <yangsita@gmail.com> | 2013-07-24 01:21:26 +0200 |
commit | de052ca6fc1c73e2857801a1bcf48c18910bec40 (patch) | |
tree | e4254800ae856c194a61efdb61bd07ea35013c04 /lib/imap.c | |
parent | 1a593191c2769a47b8c3e4d9715ec9f6dddf5e36 (diff) |
string formatting: fix 25+ printf-style format strings
Diffstat (limited to 'lib/imap.c')
-rw-r--r-- | lib/imap.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/imap.c b/lib/imap.c index b13bd3da7..3547a3467 100644 --- a/lib/imap.c +++ b/lib/imap.c @@ -77,6 +77,7 @@ #include "url.h" #include "rawstr.h" #include "curl_sasl.h" +#include "warnless.h" #define _MPRINTF_REPLACE /* use our functions only */ #include <curl/mprintf.h> @@ -398,7 +399,7 @@ static void state(struct connectdata *conn, imapstate newstate) if(imapc->state != newstate) infof(conn->data, "IMAP %p state change from %s to %s\n", - imapc, names[imapc->state], names[newstate]); + (void *)imapc, names[imapc->state], names[newstate]); #endif imapc->state = newstate; @@ -2069,7 +2070,7 @@ static CURLcode imap_sendf(struct connectdata *conn, const char *fmt, ...) /* Calculate the tag based on the connection ID and command ID */ snprintf(imapc->resptag, sizeof(imapc->resptag), "%c%03d", - 'A' + (conn->connection_id % 26), imapc->cmdid); + 'A' + curlx_sltosi(conn->connection_id % 26), imapc->cmdid); /* Prefix the format with the tag */ taggedfmt = aprintf("%s %s", imapc->resptag, fmt); |