procmail
[Top] [All Lists]

Procmail vs perl script syntax

2006-08-14 17:53:40
I am trying to use a procmail recipe that first runs a perl script to get the "remote IP" of a message, but I have a syntax error in the perl script. Got the script from SORBS.

The error is shown in the variable used for the first line of the script.

What should I do with this variable to make it right?


@msg = ;  <---THIS cause error

foreach $line ( @msg )
{
        chop $line;

        if( $line =~ /.*\[(\d+.*)\]/ )
        {
                $REMOTEIP = $1;
                last;
        }
}
print STDOUT ( $REMOTEIP );


Thanks for any tips.

Jack

_________________________________________________________________
Is your PC infected? Get a FREE online computer virus scan from McAfee® Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963


____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail
<Prev in Thread] Current Thread [Next in Thread>