diff -rNp1 ../mutt-1.2.4/Makefile.am ./Makefile.am *** ../mutt-1.2.4/Makefile.am Thu Jun 22 13:28:16 2000 --- ./Makefile.am Thu Jul 27 21:40:14 2000 *************** mutt_SOURCES = $(BUILT_SOURCES) \ *** 36,38 **** status.c system.c thread.c charset.c history.c lib.c \ ! muttlib.c editmsg.c --- 36,38 ---- status.c system.c thread.c charset.c history.c lib.c \ ! muttlib.c editmsg.c backref.c diff -rNp1 ../mutt-1.2.4/Makefile.in ./Makefile.in *** ../mutt-1.2.4/Makefile.in Fri Jul 7 01:08:06 2000 --- ./Makefile.in Thu Jul 27 21:40:25 2000 *************** BUILT_SOURCES = keymap_defs.h *** 123,125 **** bin_PROGRAMS = mutt @DOTLOCK_TARGET@ @PGPAUX_TARGET@ ! mutt_SOURCES = $(BUILT_SOURCES) addrbook.c alias.c attach.c base64.c browser.c buffy.c color.c commands.c complete.c compose.c copy.c curs_lib.c curs_main.c date.c edit.c enter.c flags.c init.c filter.c from.c getdomain.c handler.c hash.c hdrline.c headers.c help.c hook.c keymap.c main.c mbox.c menu.c mh.c mx.c pager.c parse.c pattern.c postpone.c query.c recvattach.c recvcmd.c rfc822.c rfc1524.c rfc2047.c rfc2231.c score.c send.c sendlib.c signal.c sort.c status.c system.c thread.c charset.c history.c lib.c muttlib.c editmsg.c --- 123,125 ---- bin_PROGRAMS = mutt @DOTLOCK_TARGET@ @PGPAUX_TARGET@ ! mutt_SOURCES = $(BUILT_SOURCES) addrbook.c alias.c attach.c base64.c browser.c buffy.c color.c commands.c complete.c compose.c copy.c curs_lib.c curs_main.c date.c edit.c enter.c flags.c init.c filter.c from.c getdomain.c handler.c hash.c hdrline.c headers.c help.c hook.c keymap.c main.c mbox.c menu.c mh.c mx.c pager.c parse.c pattern.c postpone.c query.c recvattach.c recvcmd.c rfc822.c rfc1524.c rfc2047.c rfc2231.c score.c send.c sendlib.c signal.c sort.c status.c system.c thread.c charset.c history.c lib.c muttlib.c editmsg.c backref.c *************** recvattach.o recvcmd.o rfc822.o rfc1524. *** 190,192 **** send.o sendlib.o signal.o sort.o status.o system.o thread.o charset.o \ ! history.o lib.o muttlib.o editmsg.o mutt_LDFLAGS = --- 190,192 ---- send.o sendlib.o signal.o sort.o status.o system.o thread.o charset.o \ ! history.o lib.o muttlib.o editmsg.o backref.o mutt_LDFLAGS = *************** DISTFILES = $(DIST_COMMON) $(SOURCES) $( *** 207,209 **** ! TAR = tar GZIP_ENV = --best --- 207,209 ---- ! TAR = gtar GZIP_ENV = --best *************** distdir: $(DISTFILES) *** 473,475 **** if test -d $$d/$$file; then \ ! cp -pr $$d/$$file $(distdir)/$$file; \ else \ --- 473,475 ---- if test -d $$d/$$file; then \ ! cp -pr $$/$$file $(distdir)/$$file; \ else \ *************** distdir: $(DISTFILES) *** 491,656 **** $(MAKE) $(AM_MAKEFLAGS) top_distdir="$(top_distdir)" distdir="$(distdir)" dist-hook - addrbook.o: addrbook.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mapping.h sort.h - alias.o: alias.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h - attach.o: attach.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mutt_curses.h rfc1524.h mime.h pager.h mailbox.h copy.h mx.h \ - pgp.h pgplib.h - base64.o: base64.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mime.h - browser.o: browser.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h buffy.h mapping.h sort.h mailbox.h browser.h - buffy.o: buffy.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h buffy.h mailbox.h mx.h - charset.o: charset.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h charset.h - color.o: color.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h mapping.h - commands.o: commands.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h mime.h sort.h mailbox.h copy.h mx.h pager.h pgp.h \ - pgplib.h - complete.o: complete.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h - compose.o: compose.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h rfc1524.h mime.h attach.h mapping.h mailbox.h \ - sort.h charset.h pgp.h pgplib.h - copy.o: copy.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mailbox.h mx.h copy.h rfc2047.h parse.h mime.h \ - pgp.h pgplib.h - curs_lib.o: curs_lib.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mutt_curses.h pager.h - curs_main.o: curs_main.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h mailbox.h mapping.h sort.h buffy.h pgp.h pgplib.h - date.o: date.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - editmsg.o: editmsg.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h copy.h mailbox.h mx.h - edit.o: edit.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h - enter.o: enter.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mutt_curses.h history.h - extlib.o: extlib.c lib.h config.h - filter.o: filter.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - flags.o: flags.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h sort.h mx.h mailbox.h - from.o: from.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - getdomain.o: getdomain.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h - gnupgparse.o: gnupgparse.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h pgp.h pgplib.h charset.h mime.h - handler.o: handler.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h rfc1524.h keymap.h \ - keymap_defs.h mime.h copy.h charset.h pgp.h pgplib.h - hash.o: hash.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - hdrline.o: hdrline.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h sort.h pgp.h pgplib.h - headers.o: headers.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h pgp.h pgplib.h - help.o: help.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h keymap.h keymap_defs.h pager.h \ - mapping.h - history.o: history.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h history.h - hook.o: hook.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - init.o: init.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mapping.h mutt_curses.h history.h keymap.h \ - keymap_defs.h pgp.h pgplib.h mx.h mailbox.h init.h sort.h \ - buffy.h - keymap.o: keymap.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mutt_curses.h mapping.h functions.h - lib.o: lib.c lib.h config.h - main.o: main.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mx.h mailbox.h buffy.h sort.h pgp.h pgplib.h \ - mutt_curses.h keymap.h keymap_defs.h reldate.h - makedoc.o: makedoc.c config.h - mbox.o: mbox.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mailbox.h mx.h sort.h copy.h - menu.o: menu.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h - mh.o: mh.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h lib.h \ - globals.h mailbox.h mx.h copy.h buffy.h sort.h - mutt_dotlock.o: mutt_dotlock.c dotlock.h config.h reldate.h - muttlib.o: muttlib.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mime.h mailbox.h mx.h \ - pgp.h pgplib.h - mx.o: mx.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h lib.h \ - globals.h mx.h mailbox.h rfc2047.h sort.h copy.h keymap.h \ - keymap_defs.h pgp.h pgplib.h dotlock.h - pager.o: pager.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h keymap.h keymap_defs.h \ - mutt_menu.h mapping.h sort.h pager.h attach.h pgp.h pgplib.h - parse.o: parse.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mailbox.h mime.h rfc2047.h rfc2231.h pgp.h \ - pgplib.h - pattern.o: pattern.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mapping.h keymap.h keymap_defs.h \ - mailbox.h copy.h pgp.h pgplib.h - pgpinvoke.o: pgpinvoke.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h pgp.h pgplib.h - pgpkey.o: pgpkey.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h mime.h pgp.h pgplib.h pager.h sort.h - pgplib.o: pgplib.c lib.h config.h pgplib.h - pgp.o: pgp.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h lib.h \ - globals.h mutt_curses.h pgp.h pgplib.h mime.h parse.h - pgppubring.o: pgppubring.c config.h sha.h lib.h pgplib.h - postpone.o: postpone.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - rfc1524.h mime.h mailbox.h mapping.h pgp.h pgplib.h - query.o: query.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_menu.h keymap.h keymap_defs.h mapping.h \ - sort.h - recvattach.o: recvattach.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h rfc1524.h mime.h mailbox.h attach.h mapping.h \ - mx.h copy.h pgp.h pgplib.h - recvcmd.o: recvcmd.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h mutt_menu.h keymap.h \ - keymap_defs.h rfc1524.h mime.h mailbox.h attach.h mapping.h \ - mx.h copy.h - resize.o: resize.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h - rfc1524.o: rfc1524.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h rfc1524.h - rfc2047.o: rfc2047.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mime.h charset.h rfc2047.h - rfc2231.o: rfc2231.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mime.h charset.h rfc2047.h rfc2231.h - rfc822.o: rfc822.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - score.o: score.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h sort.h - sendlib.o: sendlib.c mutt.h config.h rfc822.h hash.h mutt_regex.h \ - protos.h lib.h globals.h mutt_curses.h rfc2047.h rfc2231.h mx.h \ - mailbox.h mime.h copy.h pager.h charset.h pgp.h pgplib.h - send.o: send.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h rfc2047.h keymap.h keymap_defs.h \ - mime.h mailbox.h copy.h mx.h pgp.h pgplib.h - sha1dgst.o: sha1dgst.c sha.h sha_locl.h - signal.o: signal.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_curses.h - sort.o: sort.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h sort.h - status.o: status.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h mutt_menu.h keymap.h keymap_defs.h \ - mutt_curses.h sort.h mapping.h mx.h mailbox.h - system.o: system.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h - thread.o: thread.c mutt.h config.h rfc822.h hash.h mutt_regex.h protos.h \ - lib.h globals.h sort.h - info-am: --- 491,492 ---- diff -rNp1 ../mutt-1.2.4/VERSION ./VERSION *** ../mutt-1.2.4/VERSION Fri Jul 7 01:06:44 2000 --- ./VERSION Fri Jul 28 16:56:37 2000 *************** *** 1 **** ! 1.2.4 --- 1 ---- ! 1.2.4br diff -rNp1 ../mutt-1.2.4/backref.c ./backref.c *** ../mutt-1.2.4/backref.c Thu Jan 1 01:00:00 1970 --- ./backref.c Fri Jul 28 18:07:27 2000 *************** *** 0 **** --- 1,87 ---- + #include "mutt.h" + #include "backref.h" + + #define MIN(a, b) ( (a < b) ? a : b ) + + static struct pattern_t * + backref_find_pattern(struct pattern_t *pattern) + { + struct pattern_t *pat, *ret; + + for (pat = pattern; pat; pat = pat->next) + { + if (pat->pmatch[0].rm_so != -1 && pat->matched) + return pat; + if ( (ret = backref_find_pattern(pat->child)) ) + return ret; + } + + + return 0; + } + + void mutt_resolve_backreference(char *target, size_t slen, + const char *s, struct pattern_t *pattern) + { + char *cp1, *cp2, *eos; /* generic char pointer */ + size_t len; + struct pattern_t *pat; + regmatch_t *pmatch; + const char *t; + + if ( !( pat = backref_find_pattern(pattern)) ) /* no match found */ + { + snprintf(target, slen, "%s", s); + return; + } + + pmatch = pat->pmatch; + t = pat->matched; + + cp1 = (char *)s; + cp2 = target; + eos = cp2 + slen; + + while ( *cp1 && cp2 < eos ) + { + int number; + + if (*cp1 != '$') + { + *cp2++ = *cp1++; + continue; + } + cp1++; /* skip '$' */ + + if (!(*cp1 >= '0' && *cp1 <= '9')) /* Not A Number(tm) */ + { + *cp2++ = '$'; + *cp2++ = *cp1++; + continue; + } + + number = *cp1 - '0'; + if (number > M_MAX_BACKREF) /* index out of bounds */ + { + *cp2++ = '$'; + *cp2++ = *cp1++; + fprintf(stderr, "INDEX OUT OF BOUNDS: %d\n", number); + continue; + } + + if ( pmatch[number].rm_so == -1 ) /* not a valid backref */ + { + *cp2++ = '$'; + *cp2++ = *cp1++; + continue; + } + + len = MIN(pmatch[number].rm_eo - pmatch[number].rm_so + 1, eos - cp2); + len = snprintf(cp2, len, "%s", t); + cp2 += len; + cp1++; + } + *cp2++ = 0; + + } + diff -rNp1 ../mutt-1.2.4/backref.h ./backref.h *** ../mutt-1.2.4/backref.h Thu Jan 1 01:00:00 1970 --- ./backref.h Fri Jul 28 16:48:43 2000 *************** *** 0 **** --- 1,7 ---- + #ifndef M_HAVE_BACKREF_H__ + #define M_HAVE_BACKREF_H__ + + void mutt_resolve_backreference(char *, size_t, const char *, + struct pattern_t *); + + #endif diff -rNp1 ../mutt-1.2.4/browser.c ./browser.c *** ../mutt-1.2.4/browser.c Wed Apr 12 18:32:26 2000 --- ./browser.c Thu Jul 27 22:07:16 2000 *************** void _mutt_select_file (char *f, size_t *** 941,943 **** ! if ((err = REGCOMP (rx, s, REG_NOSUB)) != 0) { --- 941,943 ---- ! if ((err = REGCOMP (rx, s, 0)) != 0) { diff -rNp1 ../mutt-1.2.4/hook.c ./hook.c *** ../mutt-1.2.4/hook.c Tue May 16 17:23:12 2000 --- ./hook.c Fri Jul 28 16:45:13 2000 *************** *** 19,20 **** --- 19,21 ---- #include "mutt.h" + #include "backref.h" *************** void mutt_send_hook (HEADER *hdr) *** 321,322 **** --- 322,341 ---- + static void + mutt_prepare_backreferences(struct pattern_t *pat) + { + struct pattern_t *pattern = pat; + + if (!pat) + return; + + memset(pattern->pmatch, -1, sizeof(regmatch_t) * M_MAX_BACKREF); + for (; pattern; pattern = pattern->next) + { + pattern->matched = 0; + memset(pattern->pmatch, -1, sizeof(regmatch_t) * M_MAX_BACKREF); + mutt_prepare_backreferences(pattern->child); + } + + } + static int *************** mutt_addr_hook (char *path, size_t pathl *** 332,333 **** --- 351,354 ---- + mutt_prepare_backreferences(hook->pattern); + if (hook->type & type) *************** mutt_addr_hook (char *path, size_t pathl *** 335,337 **** { ! mutt_make_string (path, pathlen, hook->command, ctx, hdr); return 0; --- 356,371 ---- { ! if (strstr(hook->command, "$")) ! { ! char *new_command = malloc(pathlen); ! if (new_command) ! { ! mutt_resolve_backreference(new_command, pathlen, ! hook->command, hook->pattern); ! ! mutt_make_string(path, pathlen, new_command, ctx, hdr); ! free(new_command); ! return 0; ! } ! } ! mutt_make_string (path, pathlen, hook->command, ctx, hdr); return 0; diff -rNp1 ../mutt-1.2.4/menu.c ./menu.c *** ../mutt-1.2.4/menu.c Fri Mar 3 11:10:10 2000 --- ./menu.c Thu Jul 27 22:06:58 2000 *************** static int menu_search (MUTTMENU *menu, *** 680,682 **** ! if ((r = REGCOMP (&re, menu->searchBuf, REG_NOSUB | mutt_which_case (menu->searchBuf))) != 0) { --- 680,682 ---- ! if ((r = REGCOMP (&re, menu->searchBuf, mutt_which_case (menu->searchBuf))) != 0) { diff -rNp1 ../mutt-1.2.4/mutt.h ./mutt.h *** ../mutt-1.2.4/mutt.h Thu Jun 8 12:00:14 2000 --- ./mutt.h Fri Jul 28 16:44:19 2000 *************** *** 35,36 **** --- 35,44 ---- + #define HAVE_BACKREFERENCES 1 + #if HAVE_BACKREFERENCES + /* anything with 2 digits would require a slighty more complex parser + which is something i will do on demand :) + */ + #define M_MAX_BACKREF 9 + #endif + #include "rfc822.h" *************** typedef struct pattern_t *** 633,634 **** --- 641,644 ---- regex_t *rx; + regmatch_t pmatch[M_MAX_BACKREF]; /* for backreferences */ + const char *matched; /* 'template' for backrefs */ } pattern_t; diff -rNp1 ../mutt-1.2.4/pattern.c ./pattern.c *** ../mutt-1.2.4/pattern.c Sun Apr 9 14:27:37 2000 --- ./pattern.c Fri Jul 28 17:15:22 2000 *************** int eat_regexp (pattern_t *pat, BUFFER * *** 242,244 **** pat->rx = safe_malloc (sizeof (regex_t)); ! r = REGCOMP (pat->rx, buf.data, REG_NEWLINE | REG_NOSUB | mutt_which_case (buf.data)); FREE (&buf.data); --- 242,244 ---- pat->rx = safe_malloc (sizeof (regex_t)); ! r = REGCOMP (pat->rx, buf.data, REG_NEWLINE | mutt_which_case (buf.data)); FREE (&buf.data); *************** perform_or (struct pattern_t *pat, patte *** 734,736 **** ! static int match_adrlist (regex_t *rx, int match_personal, int alladdr, int n, ...) --- 734,736 ---- ! static int match_adrlist (struct pattern_t *pat, int match_personal, int alladdr, int n, ...) *************** static int match_adrlist (regex_t *rx, i *** 739,740 **** --- 739,741 ---- ADDRESS *a; + regex_t *rx = pat->rx; *************** static int match_adrlist (regex_t *rx, i *** 745,751 **** { ! if (alladdr^ ! ((a->mailbox && regexec (rx, a->mailbox, 0, NULL, 0) == 0) || ! (match_personal && a->personal && ! regexec (rx, a->personal, 0, NULL, 0) == 0))) { va_end (ap); --- 746,758 ---- { ! if (alladdr^ ((a->mailbox ! && regexec (rx, a->mailbox, M_MAX_BACKREF, pat->pmatch, 0) == 0))) { + pat->matched = a->mailbox; + va_end (ap); + return (! alladdr); /* Found match, or non-match if alladdr */ + } + else if (alladdr^ ((match_personal && a->personal + && regexec (rx, a->personal, M_MAX_BACKREF, pat->pmatch, 0) == 0))) + { + pat->matched = a->personal; va_end (ap); *************** mutt_pattern_exec (struct pattern_t *pat *** 847,858 **** case M_SENDER: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->sender)); case M_FROM: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->from)); case M_TO: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->to)); case M_CC: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->cc)); --- 854,865 ---- case M_SENDER: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->sender)); case M_FROM: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->from)); case M_TO: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->to)); case M_CC: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 1, h->env->cc)); *************** mutt_pattern_exec (struct pattern_t *pat *** 870,872 **** case M_ADDRESS: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 4, h->env->from, --- 877,879 ---- case M_ADDRESS: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 4, h->env->from, *************** mutt_pattern_exec (struct pattern_t *pat *** 874,876 **** case M_RECIPIENT: ! return (pat->not ^ match_adrlist (pat->rx, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 2, h->env->to, h->env->cc)); --- 881,883 ---- case M_RECIPIENT: ! return (pat->not ^ match_adrlist (pat, flags & M_MATCH_FULL_ADDRESS, pat->alladdr, 2, h->env->to, h->env->cc));