+2009-06-01 10:36 +0200 Rocco Rutte <pdmef@gmx.net> (36b7e267ce33)
+
+ * send.c: Treat address groups as no recipients
+
+ When sending with Sendmail or SMTP we exclude address groups anyway,
+ so treat these addresses as not present when checking for valid
+ recipients before sending in the compose menu.
+
+2009-06-01 10:29 +0200 Rocco Rutte <pdmef@gmx.net> (64250df0e9a4)
+
+ * ChangeLog, smtp.c: Weed out address groups for SMTP the same way we
+ do for sendmail
+
2009-05-31 19:19 -0700 Brendan Cully <brendan@kublai.com> (0024860ab03e)
* doc/Makefile.am: Allow chunked and unchunked manuals to build in
return sysexits_h[i].str;
}
+
+int mutt_atos (const char *str, short *dst)
+{
+ int rc;
+ long res;
+ short tmp;
+ short *t = dst ? dst : &tmp;
+
+ *t = 0;
+
+ if ((rc = mutt_atol (str, &res)) < 0)
+ return rc;
+ if ((short) res != res)
+ return -2;
+
+ *t = (short) res;
+ return 0;
+}
+
+int mutt_atoi (const char *str, int *dst)
+{
+ int rc;
+ long res;
+ int tmp;
+ int *t = dst ? dst : &tmp;
+
+ *t = 0;
+
+ if ((rc = mutt_atol (str, &res)) < 0)
+ return rc;
+ if ((int) res != res)
+ return -2;
+
+ *t = (int) res;
+ return 0;
+}
+
+int mutt_atol (const char *str, long *dst)
+{
+ long r;
+ long *res = dst ? dst : &r;
+ char *e = NULL;
+
+ /* no input: 0 */
+ if (!str || !*str)
+ {
+ *res = 0;
+ return 0;
+ }
+
+ *res = strtol (str, &e, 10);
+ if (e && *e != '\0')
+ return -1;
+ return 0;
+}
char *safe_strncat (char *, size_t, const char *, size_t);
char *safe_strdup (const char *);
+/* strtol() wrappers with range checking; they return
+ * 0 success
+ * -1 format error
+ * -2 overflow (for int and short)
+ * the int pointer may be NULL to test only without conversion
+ */
+int mutt_atos (const char *, short *);
+int mutt_atoi (const char *, int *);
+int mutt_atol (const char *, long *);
+
const char *mutt_stristr (const char *, const char *);
const char *mutt_basename (const char *);