Article View: news.software.nntp
Article #20639Help with Perl hooks on INN 1.5.1, please
From: Andrew Cormack - COMPG
Date: Mon, 18 Aug 1997 00:00
Date: Mon, 18 Aug 1997 00:00
33 lines
2195 bytes
2195 bytes
I'm trying to write a Perl filter_nnrpd.pl program which will check
that the headers on locally posted news articles contain valid return
mail addresses. This is working fine, except when I try to attach to
the DBM file which contains the list of valid addresses, the following
appears in the news.notice log file:
nnrpd[6075]: Perl function filter_post died: AnyDBM_File doesn't define \
a TIEHASH method at /usr/news/bin/control/filter_nnrpd.pl line 120
nnrpd[6075]: peth.comp.cf.ac.uk perl filtering disabled
The offending code seems to be a call to dbmopen(), since the filter works
fine if I comment that out. However if I write a main program to call the
filtering routine, and run that on its own on the same machine, it works
fine, even with the dbmopen() call.
I'd be very grateful for any suggestion what the difference might be
between running my routine stand-alone and as a INN subroutine,
especially if someone can suggest what I need to add to my program to
make it work. This is Perl 5.004, by the way.
Thanks,
Andrew
--
+-----------------------------------------------------------------+
| Andrew Cormack | email: cormack@cardiff.ac.uk |
| Information Systems Support, | snail: 40/41 Park Place, Cardiff |
| postmaster and webmaster | CF1 3BB |
| University of Wales, Cardiff | |
+-----------------------------------------------------------------+
Technical Details
Message-ID:
<EF43vy.5D7@cf.ac.uk>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mailShow Full Headers
Complete Article Headers
Message-ID: <EF43vy.5D7@cf.ac.uk> Subject: Help with Perl hooks on INN 1.5.1, please Date: Mon, 18 Aug 1997 00:00:00 +0000 From: cormack@cf.ac.uk (Andrew Cormack - COMPG) Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!not-for-mail X-Deja-AN: 265063333 X-Nntp-Posting-Host: babel.comp.cf.ac.uk Sender: news@cf.ac.uk (Usenet News user) Organization: Posted through the Joint Cardiff Computing Service, Wales, UK Newsgroups: news.software.nntp,comp.lang.perl.misc