Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!zaphod.mps.ohio-state.edu!cis.ohio-state.edu!ucbvax!dmr.asa.com!sean From: sean@dmr.asa.com (Sean Baker) Newsgroups: comp.mail.mh Subject: Checking if recipient is on To: or Cc: list Message-ID: <1156.675633494@smb> Date: 30 May 91 19:58:14 GMT Sender: daemon@ucbvax.BERKELEY.EDU Reply-To: sean@dmr.asa.com Distribution: world Organization: The Internet Lines: 32 Does anyone know of a good way to tell whether the recipient of a message is on the To: or Cc: list of the message? I'm trying to do some maildelivery stuff, and I have a function that I'd like to perform only if the recipient is in the To: list of addresses. I've tried passing the maildelivery variable $(address) to my program, but this variable always expands to the user name, not the actual address in the To: or Cc: line. If the $(address) expanded to the actual address in the message text, I could just grep for that in the To: and Cc: lines to see which one it was contained in. With aliasing and all, this is seeming more and more to be nearly impossible to do reliably. Or, perhaps (hopefully), I'm just missing something. Any help would be greatly appreciated. If I have not made myself clear as to what I'm asking, please let me know and I'll try to clarify. Thanks, Sean. ======================================= Sean Baker Data Management Resources 20725 South Western Avenue, Suite 100 Torrance, CA 90501 USA (213)618-9677