STAILQ_FOREACH(sp, &SpamList, entries)
{
mutt_md5_process(sp->regex->pattern, &md5ctx);
- mutt_md5_process(sp->tmpl, &md5ctx);
+ mutt_md5_process(sp->templ, &md5ctx);
}
/* Mix in user's nospam list */
* re-adds conceptually. So we probably want this to imply a
* removal, then do an add. We can achieve the removal by freeing
* the template, and leaving t pointed at the current item. */
- FREE(&np->tmpl);
+ FREE(&np->templ);
break;
}
}
}
/* Now np is the ReplaceListNode that we want to modify. It is prepared. */
- np->tmpl = mutt_str_strdup(templ);
+ np->templ = mutt_str_strdup(templ);
/* Find highest match number in template string */
np->nmatch = 0;
mutt_debug(LL_DEBUG5, "%s matches %s\n", src, np->regex->pattern);
/* Copy into other twinbuf with substitutions */
- if (np->tmpl)
+ if (np->templ)
{
- for (p = np->tmpl; *p && (tlen < 1023);)
+ for (p = np->templ; *p && (tlen < 1023);)
{
if (*p == '%')
{
{
STAILQ_REMOVE(rl, np, ReplaceListNode, entries);
mutt_regex_free(&np->regex);
- FREE(&np->tmpl);
+ FREE(&np->templ);
FREE(&np);
}
}
mutt_debug(LL_DEBUG5, "%d subs\n", (int) np->regex->regex->re_nsub);
/* Copy template into buf, with substitutions. */
- for (p = np->tmpl; *p && tlen < buflen - 1;)
+ for (p = np->templ; *p && tlen < buflen - 1;)
{
/* backreference to pattern match substring, eg. %1, %2, etc) */
if (*p == '%')
{
STAILQ_REMOVE(rl, np, ReplaceListNode, entries);
mutt_regex_free(&np->regex);
- FREE(&np->tmpl);
+ FREE(&np->templ);
FREE(&np);
nremoved++;
}
{
struct Regex *regex; /**< Regex containing a regular expression */
size_t nmatch; /**< Match the 'nth' occurrence (0 means the whole expression) */
- char *tmpl; /**< Template to match */
+ char *templ; /**< Template to match */
STAILQ_ENTRY(ReplaceListNode) entries; /**< Next item in list */
};
STAILQ_HEAD(ReplaceList, ReplaceListNode);