Procmail recipe doesn't stop


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers Procmail recipe doesn't stop
# 15  
Old 02-02-2005
Dear elmonty,

In the example below, procmail uses the f, b and w flags. That might help you.

Code:
:0
* ^Content-Type: *text/plain
{
  :0 fbw
  * ^Content-Transfer-Encoding: *quoted-printable
  | mimencode -u -q

  :0 Afhw 
  | formail -I "Content-Transfer-Encoding: 8bit"

  :0 fbw 
  * ^Content-Transfer-Encoding: *base64 | mimencode -u -b

  :0 Afhw 
  | formail -I "Content-Transfer-Encoding: 8bit" 
}

# 16  
Old 02-03-2005
Well, I don't want to use the PHP script as a filter. And I don't want to put a lock or a wait on it, because it could be running for a while. Its purpose is to launch a task that will process all the messages in the queue folder.

I couldn't see anything in the manual that explains this behavior.
# 17  
Old 02-03-2005
Based on my read of how procmail works, you must put a wait on it (and maybe a lockfile) because procmail will not wait for the PHP script to return (does not generate the successful return code), and this seems to perhaps explain what you are observing.

This also seems to explain why your hack is required, based on my read of the examples and documents.
Neo
# 18  
Old 02-03-2005
Two thoughts:

1. It doesn't explain why the delivery stops for plain text mails but not HTML mails. The current version of the PHP script isn't doing any processing of the message at all -- it's just a placeholder. And its logic doesn't treat HTML mails any differently. It just forwards the message to multiple recipients.

2. According to what I've read of how procmail works, it shouldn't matter what the script does or whether it waits. If procmail calls a program and the c or f flags aren't specified, it's supposed to stop delivery.
# 19  
Old 02-03-2005
I agree.

I'm not a procmail expert and have ran out of clues.

Thanks for the dialog. Sorry I could not help more.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

5 More Discussions You Might Find Interesting

1. Linux

Set -n doesn't stop executing

When I do "set -n" or "set -o noexec" the shell doesn't do what it sould. Infact if I check: $: set -o .... noexec off .... f ...instead I can set normally the other option. Who Knows what could be up? (2 Replies)
Discussion started by: flaviofachin
2 Replies

2. UNIX for Dummies Questions & Answers

Make - two target produced by one recipe

Suppose executable X produces files A and B from nothing, Y produces C from A, Z produces D from B, and my final goal is to produce C and D. I wrote the following makefile: .PHONY: all all: C D C: A Y A D: B Z B A B: X This makefile seems to reflect all dependencies, as it should... (2 Replies)
Discussion started by: ybelenky
2 Replies

3. UNIX for Dummies Questions & Answers

Script that doesn't stop

Hi all, I got a script that runs automatically using the cron file. The script starts running at midnight and suppose to delete image files from folders and sub-folders. The script ends when he finishes deleting or after 5 hours. My problem is that the script doesn't stop running even after 5... (3 Replies)
Discussion started by: biot
3 Replies

4. Email Antispam Techniques and Email Filtering

Procmail recipe: From "number spam"

This procmail recipe catches a lot of spam, but might accidently catch a friendly email occasionally: :0 * ^From:.*()+.*@ number_spam ... trapping user names in the From header field that have 3 or more numbers. (0 Replies)
Discussion started by: Neo
0 Replies

5. Email Antispam Techniques and Email Filtering

Procmail recipe: blocking 'unsubscribe and opt-out' messages....

Here is a crude procmail recipe that I quickly created (NOT a procmail recipe expert, btw) that has been catching lots of spam (current second after the charset_spam recipe posted earlier): :0B * .*If.you.do.not.wish.to.receive...* more_spam :0B * You.requested.to.receive.this.mailing... (0 Replies)
Discussion started by: Neo
0 Replies
Login or Register to Ask a Question