Package: vacation
Version: 3.3.0
Severity: normal
Tags: Patch
the current version of vaction needs an upper case first letter in mail
headers. Although this is common practice there are rare examples of
mails with all lowercase header field names. vacation won't recognize a
'to:' header and won't answer the mail.
Solution is simple: Just add the lowercase case in the switch statement,
as the function use strncasecomp anyway (not for 'From', why?):
# diff -c vacation.c.orig vacation.c
*** vacation.c.orig 2006-06-02 00:16:18.000000000 +0200
--- vacation.c 2006-06-02 00:26:14.000000000 +0200
***************
*** 301,306 ****
--- 301,307 ----
cont = tome = 0;
while (fgets(buf, sizeof(buf), stdin) && *buf != '\n')
switch(*buf) {
+ case 'f':
case 'F': /* "From " */
cont = 0;
if (!strncmp(buf, "From ", 5)) {
***************
*** 313,318 ****
--- 314,320 ----
discard_exit();
}
break;
+ case 'r':
case 'R': /* "Return-Path:" */
/* EvB: this may use Name
<[EMAIL PROTECTED]> */
cont = 0;
***************
*** 328,333 ****
--- 330,336 ----
if (junkmail())
discard_exit();
break;
+ case 'p':
case 'P': /* "Precedence:" */
cont = 0;
if (strncasecmp(buf, "Precedence", 10) ||
***************
*** 344,349 ****
--- 347,353 ----
!strncasecmp(p, "list", 4))
discard_exit();
break;
+ case 's':
case 'S': /* "Subject" */
cont = 0;
if (strncasecmp(buf, "Subject:", 8) ||
***************
*** 354,364 ****
--- 358,370 ----
if ((p = strchr(subj, '\n')))
*p = '\0';
break;
+ case 'c':
case 'C': /* "Cc:" */
if (strncasecmp(buf, "Cc:", 3))
break;
cont = 1;
goto findme;
+ case 't':
case 'T': /* "To:" */
if (strncasecmp(buf, "To:", 3))
break;
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]