X-Git-Url: https://git.madduck.net/etc/mailfilter.git/blobdiff_plain/bc44168d4736169c38c92f94cb40e34fbb6e7ccf..e86438abb235192645607a71137b5acdf208cc00:/procmail/get-msgid diff --git a/procmail/get-msgid b/procmail/get-msgid index c1260ac..50fbef4 100644 --- a/procmail/get-msgid +++ b/procmail/get-msgid @@ -10,7 +10,7 @@ { LOG="get-msgid: lacking message-id, using resent-message-id...$NL" :0 fw - |$FORMAIL -R Resent-Message-Id Message-Id + |$FORMAIL -R Resent-Message-ID Message-ID } :0 E @@ -36,13 +36,8 @@ *$ MSGID ?? .+@$RE_MAILRELAYS> *$ !^Return-Path: .+@$RE_MAILRELAYS\> *$ !^Received: by $RE_MAILRELAYS \(postfix, from userid +* MSGID ?? ^<\/[^>]+ { LOG="get-msgid: missing message ID added by one of our mail relays$NL" - - :0 fw - |$SED -re "s/^([Mm]essage-[Ii][Dd]:[^@]+@$RE_MAILRELAYS)\>/\1.MSGID-ADDED/" - - :0 - * ^Message-Id:[ ]*\/[^ ]+ - { MSGID="$MATCH" } + MSGID="<${MATCH}.MSGID-ADDED>" }