projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
searchheaders
[unix-history]
/
usr
/
src
/
usr.bin
/
mail
/
list.c
diff --git
a/usr/src/usr.bin/mail/list.c
b/usr/src/usr.bin/mail/list.c
index
7d06f65
..
12021c6
100644
(file)
--- a/
usr/src/usr.bin/mail/list.c
+++ b/
usr/src/usr.bin/mail/list.c
@@
-6,7
+6,7
@@
*/
#ifndef lint
*/
#ifndef lint
-static char sccsid[] = "@(#)list.c 5.1
5
(Berkeley) %G%";
+static char sccsid[] = "@(#)list.c 5.1
6
(Berkeley) %G%";
#endif /* not lint */
#include "rcv.h"
#endif /* not lint */
#include "rcv.h"
@@
-667,8
+667,15
@@
matchsubj(str, mesg)
* Now look, ignoring case, for the word in the string.
*/
* Now look, ignoring case, for the word in the string.
*/
- cp = str;
- cp2 = hfield("subject", mp);
+ if (value("searchheaders") && (cp = index(str, ':'))) {
+ *cp++ = '\0';
+ cp2 = hfield(str, mp);
+ cp[-1] = ':';
+ str = cp;
+ } else {
+ cp = str;
+ cp2 = hfield("subject", mp);
+ }
if (cp2 == NOSTR)
return(0);
backup = cp2;
if (cp2 == NOSTR)
return(0);
backup = cp2;