Strange perl filter bug
Russ Allbery
rra at stanford.edu
Sun Dec 11 20:46:18 UTC 2005
Christoph Biedl <cbiedl at gmx.de> writes:
> A friend of mine complained that his perl filter (cleanfeed) does not
> catch binaries while other spew is detected, e.g. EMP-md5. After a
> longish debugging session I finally found that the multi-line tests like
> "$hdr{__BODY__} =~ /(...)/m" never match. Reproducing failed: Testing
> the very same data in a standalone perl script was successfull.
> Things are even more strange:
> - System is a Debian sarge Linux, the same problem existed already when
> it was woody, i.e. different INN version, different Perl version.
> - I could not reproduce this on any other (Debian) system. I assume that
> there's something specific on that server that even survives upgrades
> but I have no idea what this might be.
> - Finally: Copying the variable "$BODY = $hdr{__BODY__};" and doing all
> the tests against $BODY caused the trouble to go away. This is of
> course a workaround, not a solution.
> Now I ran out of ideas what goes wrong here and how it could be cured.
> Any hint what else I could check?
I have no idea on this. INN does pull some performance hacks to try to
avoid copying the body of the article, since that produced a noticable
performance gain, so $hdr{__BODY__} is internally special in a way that
the copy of it isn't. But I have no idea why this would produce those
symptoms, and particularly only on a particular machine.
--
Russ Allbery (rra at stanford.edu) <http://www.eyrie.org/~eagle/>
Please send questions to the list rather than mailing me directly.
<http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
More information about the inn-workers
mailing list