{
md5_buffer (folder, strlen (folder), &md5sum);
+ /* On some systems (e.g. OS X), snprintf is defined as a macro.
+ * Embedding directives inside macros is undefined, so we have to duplicate
+ * the whole call:
+ */
+#ifndef HAVE_ICONV
ret = snprintf(hcpath, _POSIX_PATH_MAX,
"%s/%02x%02x%02x%02x%02x%02x%02x%02x"
"%02x%02x%02x%02x%02x%02x%02x%02x"
-#ifndef HAVE_ICONV
"-%s"
-#endif
,
path, md5sum[0], md5sum[1], md5sum[2], md5sum[3],
md5sum[4], md5sum[5], md5sum[6], md5sum[7], md5sum[8],
md5sum[9], md5sum[10], md5sum[11], md5sum[12],
md5sum[13], md5sum[14], md5sum[15]
-#ifndef HAVE_ICONV
,chs
-#endif
);
+#else
+ ret = snprintf(hcpath, _POSIX_PATH_MAX,
+ "%s/%02x%02x%02x%02x%02x%02x%02x%02x"
+ "%02x%02x%02x%02x%02x%02x%02x%02x"
+ ,
+ path, md5sum[0], md5sum[1], md5sum[2], md5sum[3],
+ md5sum[4], md5sum[5], md5sum[6], md5sum[7], md5sum[8],
+ md5sum[9], md5sum[10], md5sum[11], md5sum[12],
+ md5sum[13], md5sum[14], md5sum[15]
+ );
+#endif
}
if (ret <= 0)
return (NULL);
}
-void mutt_make_help (char *d, size_t dlen, char *txt, int menu, int op)
+void mutt_make_help (char *d, size_t dlen, const char *txt, int menu, int op)
{
char buf[SHORT_STRING];
snprintf (buf, IMAP_DATELEN, "%02d-%s-%d %02d:%02d:%02d %+03d%02d",
tm->tm_mday, Months[tm->tm_mon], tm->tm_year + 1900,
tm->tm_hour, tm->tm_min, tm->tm_sec,
- (int) tz / 60, (int) abs (tz) % 60);
+ (int) tz / 60, (int) abs ((int) tz) % 60);
}
/* imap_qualify_path: make an absolute IMAP folder target, given IMAP_MBOX
void mutt_check_lookup_list (BODY *, char *, int);
void mutt_make_attribution (CONTEXT *ctx, HEADER *cur, FILE *out);
void mutt_make_forward_subject (ENVELOPE *env, CONTEXT *ctx, HEADER *cur);
-void mutt_make_help (char *, size_t, char *, int, int);
+void mutt_make_help (char *, size_t, const char *, int, int);
void mutt_make_misc_reply_headers (ENVELOPE *env, CONTEXT *ctx, HEADER *cur, ENVELOPE *curenv);
void mutt_make_post_indent (CONTEXT *ctx, HEADER *cur, FILE *out);
void mutt_merge_envelopes(ENVELOPE* base, ENVELOPE** extra);
snprintf (s, len, "Date: %s, %d %s %d %02d:%02d:%02d %+03d%02d\n",
Weekdays[l->tm_wday], l->tm_mday, Months[l->tm_mon],
l->tm_year + 1900, l->tm_hour, l->tm_min, l->tm_sec,
- (int) tz / 60, (int) abs (tz) % 60);
+ (int) tz / 60, (int) abs ((int) tz) % 60);
return (s);
}