procmail
[Top] [All Lists]

Re: Procmail 3.22 running out of memory

2002-04-16 12:50:02
On Tue, 16 Apr 2002 the voices made David W. Tamkin write:

Procmail 3.22 has that problems with variable capture recipes under many
OSes.  For now, the workaround is to use a backquote assignment instead:

 :0 flags
 * conditions
 { VARIABLE=`command` }

That can be a pain, though, if there would have been an `h' flag (without
`b') or `b' (without `h') on the variable capture recipe in order to feed
only the head or only the body to the command.  Unfortunately, the only way
to do that seems to be to use another program to remove the part that
shouldn't be fed and to pipe it to the command:

 Why not simply have the "trigger" on the outside, like it is, and then do
":0b" (or whatever it is you want) inside it... ie a second recipe?

 VARIABLE=`sed '/^$/q | command`    # simulates `h'
 VARIABLE=`formail -X "" | command` # simulates `h'
 VARIABLE=`formail -I "" | command` # simulates `b', almost
                                    # (also feeds blank line at neck)
 VARIABLE=`sed '1,/^$/d' | command` # simulates `b'

On the other hand, it makes an `i' flag unnecessary.



_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail



        /Tony
-- 
 +--------------------------------------------------------------------+
 | Per scientiam ad libertatem! // Through knowledge towards freedom! |
 | Genom kunskap mot frihet! =*= (c) 1999-2002 tony(_at_)svanstrom(_dot_)org 
=*= |
 +--------------------------------------------------------------------+

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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