/* * Copyright notice from original mutt: * Copyright (C) 1996-2000 Michael R. Elkins * * This file is part of mutt-ng, see http://www.muttng.org/. * It's licensed under the GNU General Public License, * please see the file GPL in the top level source directory. */ #if HAVE_CONFIG_H # include "config.h" #endif #include "mutt.h" #include "lib/mem.h" #include "lib/intl.h" #include "lib/str.h" #include "lib/debug.h" #include #include static const char *next_word (const char *s) { while (*s && !ISSPACE (*s)) s++; SKIPWS (s); return s; } int mutt_check_month (const char *s) { int i; for (i = 0; i < 12; i++) if (str_ncasecmp (s, Months[i], 3) == 0) return (i); return (-1); /* error */ } static int is_day_name (const char *s) { int i; if ((str_len (s) < 3) || !*(s + 3) || !ISSPACE (*(s + 3))) return 0; for (i = 0; i < 7; i++) if (str_ncasecmp (s, Weekdays[i], 3) == 0) return 1; return 0; } /* * A valid message separator looks like: * * From [ ]