Closed p5pRT closed 21 years ago
This is a bug report for perl from eigenstr@sol.mixi.net\, generated with the help of perlbug 1.33 running under perl v5.7.2.
-----------------------------------------------------------------
In a Sendmail::Milter script that works fine with 5.6.1\, I get the following error from 5.7.2:
ERROR: panic: unknown regstclass 222 at /usr/local/bin/spamfilter line 193.
This is the surrounding code. I included from the top of the function to provide context. Line 193 is marked with ">>>".
sub connect_callback { my $ctx = shift; my ($hostname\, $sockaddr_in) = @_;
if ($hostname eq 'localhost' or not defined($sockaddr_in)) { debug ''\, "Connect from localhost\n"; $ctx->setpriv({trusted => 1\, ipaddr => '(localhost)'}); return SMFIS_ACCEPT; }
my ($remote_port\, $iaddr) = sockaddr_in($sockaddr_in); my $remote_ip = inet_ntoa($iaddr); (my $netblock = $remote_ip) =~ s/\.\d+$//; my $remote_ip_rev; { lock $Connect_Callback_Lock_1;
my @​octets = $remote\_ip =~ /^\(\\d\+\)\\\.\(\\d\+\)\\\.\(\\d\+\)\\\.\(\\d\+\)$/;
$remote_ip_rev = join('.'\, reverse(@octets)); }
debug ''\, "Connect from $remote_ip:$remote_port ($hostname)\n";
...
"Todd R. Eigenschink" \eigenstr@​mixi\.net wrote: :In a Sendmail::Milter script that works fine with 5.6.1\, I get the :following error from 5.7.2: : :ERROR: panic: unknown regstclass 222 at /usr/local/bin/spamfilter line 193. [...] :>>> my @octets = $remote_ip =~ /^(\d+)\.(\d+)\.(\d+)\.(\d+)$/; [...] : usethreads=define use5005threads=undef useithreads=define usemultiplicity=define
Thanks for the report.
In the absence of any obvious problem with the regexp\, I'd guess this to be a threads-related corruption. Since the handling of regexp variables under threads is an area that has had active development recently you may find the problem goes away with the latest bleadperl.
If not\, it would be helpful if you could try to reduce the code to a short testcase so that we can attempt to reproduce the problem here.
Thanks\,
Hugo
"Todd R. Eigenschink" \eigenstr@​mixi\.net wrote: :I did try bleadperl rsynced this morning and the problem seems to have :disappeared. Thanks for the tip.
Thanks for the update.
Copied to p5p for the archives.
Hugo
Migrated from rt.perl.org#7329 (status was 'resolved')
Searchable as RT7329$