#endif
#include <lib-lib/mem.h>
+#include <lib-lib/str.h>
+#include <lib-lib/ascii.h>
#include "mutt.h"
-#include "ascii.h"
#include "mime.h"
#include "charset.h"
-#include "lib/str.h"
#include "rfc2047.h"
#include "rfc2231.h"
-#include "lib/mem.h"
-
#include <ctype.h>
#include <string.h>
#include <stdlib.h>
if (encoded && par->encoded)
rfc2231_decode_one (par->value, valp);
- vl = str_len (par->value);
+ vl = m_strlen(par->value);
- mem_realloc (&value, l + vl + 1);
+ p_realloc(&value, l + vl + 1);
strcpy (value + l, par->value); /* __STRCPY_CHECKED__ */
l += vl;
if (encoded)
mutt_convert_string (&value, charset, Charset, M_ICONV_HOOK_FROM);
*head = mutt_new_parameter ();
- (*head)->attribute = str_dup (attribute);
+ (*head)->attribute = m_strdup(attribute);
(*head)->value = value;
head = &(*head)->next;
}
if (!Charset || !SendCharset ||
!(charset = mutt_choose_charset (Charset, SendCharset,
- *pd, str_len (*pd), &d, &dlen))) {
- charset = str_dup (Charset ? Charset : "unknown-8bit");
+ *pd, m_strlen(*pd), &d, &dlen))) {
+ charset = m_strdup(Charset ? Charset : "unknown-8bit");
d = *pd;
- dlen = str_len (d);
+ dlen = m_strlen(d);
}
if (!mutt_is_us_ascii (charset))
++ext;
if (encode) {
- e = p_new(char, dlen + 2 * ext + str_len(charset) + 3);
+ e = p_new(char, dlen + 2 * ext + m_strlen(charset) + 3);
sprintf (e, "%s''", charset); /* __SPRINTF_CHECKED__ */
- t = e + str_len (e);
+ t = e + m_strlen(e);
for (s = d, slen = dlen; slen; s++, slen--)
if (*s < 0x20 || *s >= 0x7f ||
strchr (MimeSpecials, *s) || strchr ("*'%", *s)) {