drop the ad-hoc TZ parse, non-rfc822 compliant dates are quite rare
[apps/madmutt.git] / hdrline.c
index 79b3ea5..2bc1bed 100644 (file)
--- a/hdrline.c
+++ b/hdrline.c
 # include "config.h"
 #endif
 
-#include "mutt.h"
-#include "mutt_curses.h"
-#include "sort.h"
-#include "thread.h"
-#include "charset.h"
-#include "mutt_crypt.h"
-#include "mutt_idna.h"
+#include <ctype.h>
+#include <stdlib.h>
+#include <string.h>
+#include <locale.h>
 
+#include <lib-lib/rx.h>
 #include <lib-lib/str.h>
 
 #include <lib-mime/mime.h>
 
-#include "lib/rx.h"
+#include <lib-ui/curses.h>
 
-#include <ctype.h>
-#include <stdlib.h>
-#include <string.h>
-#include <locale.h>
+#include "mutt.h"
+#include "alias.h"
+#include "sort.h"
+#include "thread.h"
+#include "charset.h"
+#include <lib-crypt/crypt.h>
+#include "mutt_idna.h"
 
 int mutt_is_mail_list (address_t * addr)
 {
@@ -79,7 +80,7 @@ static int check_for_mailing_list_addr (address_t * adr, char *buf, int buflen)
 }
 
 
-static int first_mailing_list (char *buf, size_t buflen, address_t * a)
+static int first_mailing_list (char *buf, ssize_t buflen, address_t * a)
 {
   for (; a; a = a->next) {
     if (mutt_is_subscribed_list (a)) {
@@ -90,7 +91,7 @@ static int first_mailing_list (char *buf, size_t buflen, address_t * a)
   return 0;
 }
 
-static void make_from (ENVELOPE * hdr, char *buf, size_t len, int do_lists)
+static void make_from (ENVELOPE * hdr, char *buf, ssize_t len, int do_lists)
 {
   int me;
 
@@ -113,7 +114,7 @@ static void make_from (ENVELOPE * hdr, char *buf, size_t len, int do_lists)
     *buf = 0;
 }
 
-static void make_from_addr (ENVELOPE * hdr, char *buf, size_t len,
+static void make_from_addr (ENVELOPE * hdr, char *buf, ssize_t len,
                             int do_lists)
 {
   int me;
@@ -220,7 +221,7 @@ struct hdr_format_info {
 };
 
 static const char *hdr_format_str (char *dest,
-                                   size_t destlen,
+                                   ssize_t destlen,
                                    char op,
                                    const char *src,
                                    const char *prefix,
@@ -239,7 +240,7 @@ static const char *hdr_format_str (char *dest,
 
 #define THREAD_NEW (threads && hdr->collapsed && hdr->num_hidden > 1 && mutt_thread_contains_unread (ctx, hdr) == 1)
 #define THREAD_OLD (threads && hdr->collapsed && hdr->num_hidden > 1 && mutt_thread_contains_unread (ctx, hdr) == 2)
-  size_t len;
+  ssize_t len;
 
   hdr = hfi->hdr;
   ctx = hfi->ctx;
@@ -734,7 +735,7 @@ static const char *hdr_format_str (char *dest,
 }
 
 void
-_mutt_make_string (char *dest, size_t destlen, const char *s, CONTEXT * ctx,
+_mutt_make_string (char *dest, ssize_t destlen, const char *s, CONTEXT * ctx,
                    HEADER * hdr, format_flag flags)
 {
   struct hdr_format_info hfi;