procmail
[Top] [All Lists]

Re: Error in RC file

2017-02-22 23:31:21
On 2017-02-22 20:24, @lbutlr wrote:
[snip]
  :0fw
  | (formail -rt -I"Subject: ${LISTNAME} ${SUBJECT}" \
     -I"From: ${MOFROM}" \
     -I"To: ${MOBILE}" ; \
     echo $SMSTEXT) | $SENDMAIL -t

  :0
  .trapped/
}

LOG="END OF SMS_PROCMAIL${NL}"
VERBOSE=OFF

Two things happen with this. First, the message is not sent with the
From header I set and two, and empty (as in 0 byte) “messages” falls
through to be written in .trapped.

Frankly, it’s been too long since I really hammered on procmail much,
and most of what I knew has evaporated.

I'm a little rusty myself, but is it possible that your $SENDMAIL
doesn't think you are authorized to set "From:"?

Also, is it possible that your $SENDMAIL thinks that a 0-byte message
is an error (which would then be interpreted as failure to deliver
due to the w flag, and thus drop through to .trapped)?

You should be able to test those two things by piping something
to $SENDMAIL directly from the shell, and thereby see if the
problem is outside the script.

Stan
____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)rwth-aachen(_dot_)de
https://mailman.rwth-aachen.de/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>