rework m_strformat so that it takes the cols number to use in case of
[apps/madmutt.git] / lib-mx / compress.c
index c92853b..044392e 100644 (file)
@@ -134,13 +134,13 @@ static int get_size (const char *path)
   return (sb.st_size);
 }
 
-static const char *compresshook_format_str (char *dest, ssize_t destlen,
-                                            char op, const char *src,
-                                            const char *fmt,
-                                            const char *ifstr __attribute__ ((unused)),
-                                            const char *elstr __attribute__ ((unused)),
-                                            anytype data,
-                                            format_flag flags __attribute__ ((unused)))
+static const char *
+compresshook_format_str(char *dest, ssize_t destlen,
+                        char op, const char *src, const char *fmt,
+                        const char *ifstr __attribute__ ((unused)),
+                        const char *elstr __attribute__ ((unused)),
+                        anytype data,
+                        format_flag flags __attribute__ ((unused)))
 {
   char tmp[STRING];
 
@@ -167,10 +167,10 @@ int mutt_test_compress_command (const char *cmd)
   return (strstr (cmd, "%f") && strstr (cmd, "%t")) ? 0 : -1;
 }
 
-static char *get_compression_cmd(const char *cmd, const CONTEXT * ctx)
+static char *get_compression_cmd(const char *cmd, const CONTEXT *ctx)
 {
     char buf[_POSIX_PATH_MAX];
-    m_strformat(buf, sizeof(buf), cmd, compresshook_format_str, ctx, 0);
+    m_strformat(buf, sizeof(buf), 0, cmd, compresshook_format_str, (void*)ctx, 0);
     return m_strdup(buf);
 }