On Oct 17, Michael Weber said:
>When I try to find out what the spam score is I am getting a weird error.
It's not that weird an error. Perl is telling you exactly what's wrong,
exactly where it's wrong.
> if ( $msg[$line] =~ '^X-Spam-Level: ***********' ) {
> $bad_spam += 1;
> }
>Nested quantifiers before HERE mark in regex m/^X-Spam-Level: ** << HERE
>*********/ at /home/filter/grab.pl line 16.
>
>Why am I getting a HERE marker? Do I need to escape all the "*"s? Do I
>need to do something else?
The "<< HERE" is telling you where in the regex the problem is. The
problem is that '*' is a regex metacharacter. Just because your regex is
in single quotes (not a smart idea, because it's misleading) doesn't mean
that it's NOT a regex.
$bad_spam++ if $msg[$line] =~ /^X-Spam-Level: \*{11}/;
--
Jeff "japhy" Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/
RPI Acacia brother #734 http://www.perlmonks.org/ http://www.cpan.org/
<stu> what does y/// stand for? <tenderpuss> why, yansliterate of course.
[ I'm looking for programming work. If you like my work, let me know. ]
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]