Path: utzoo!attcan!uunet!wuarchive!uwm.edu!ux1.cso.uiuc.edu!mp.cs.niu.edu!rickert From: rickert@mp.cs.niu.edu (Neil Rickert) Newsgroups: comp.mail.mh Subject: Re: Automatic incorporation of mail into inbox Message-ID: <1990Sep30.141312.1729@mp.cs.niu.edu> Date: 30 Sep 90 14:13:12 GMT References: <15518@reed.UUCP> Organization: Northern Illinois University Lines: 37 In article <15518@reed.UUCP> trost@reed.bitnet (Bill Trost,Box 607,ext 640,) writes: > >rbeck@frc2.frc.ri.cmu.edu (Robert Beck) writes: >>I have tried: >> >>In file ".forward" -> >>| /usr/local/lib/slocal -user $USER >... >>This doesn't work - any idea what I am doing wrong? > >sendmail is rather picky about punctuation in the .forward. My >.forward is > "|/usr/new/lib/mh/slocal -user trost" > >When I remove the double-quotes from the .forward, errors like > > Sep 29 13:39:49 reed sendmail[28673]: AA28669: to=|/usr/new/lib/mh/slocal -user trost, delay=00:00:02, stat=unknown mailer error 1 > >appear in /usr/spool/mqueue/syslog. Add double quotes, and you should >be fine. > >Does anyone know the details on how sendmail parses the .forward? The comments in the code (function include() in recipient.c) imply that the file is parsed assuming each line is a comma separated list. However when one examines the actual code it appears that under some circumstances it may be parsed as a blank separated list. The quoting avoids this. The other problem the original user has was in treating $USER literally. When sendmail is running, $USER is likely to evaluate to the person who is sending the mail, or to whoever started the sendmail daemon. A quick 'grep' through the code did not find this being replaced. -- =*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*= Neil W. Rickert, Computer Science Northern Illinois Univ. DeKalb, IL 60115. +1-815-753-6940