summaryrefslogtreecommitdiff
path: root/mail/spamassassin/patches
diff options
context:
space:
mode:
authortron <tron@pkgsrc.org>2011-08-07 07:47:20 +0000
committertron <tron@pkgsrc.org>2011-08-07 07:47:20 +0000
commitfcc26d8220abd386dc697f8419d72702ec17ae06 (patch)
tree13c6114d8d15d966d02d2c10c5344999ba6462fd /mail/spamassassin/patches
parent6f5057de25b88d860572e71b7c265b180f5324f2 (diff)
downloadpkgsrc-fcc26d8220abd386dc697f8419d72702ec17ae06.tar.gz
Update "spamassassin" package to version 3.3.2. Changes since version 3.3.1:
This is a minor release, primarily to support perl-5.12 and later. Additionally several other minor bugs are fixed.
Diffstat (limited to 'mail/spamassassin/patches')
-rw-r--r--mail/spamassassin/patches/patch-bf16
-rw-r--r--mail/spamassassin/patches/patch-bg16
-rw-r--r--mail/spamassassin/patches/patch-bh16
-rw-r--r--mail/spamassassin/patches/patch-bi190
-rw-r--r--mail/spamassassin/patches/patch-bj16
-rw-r--r--mail/spamassassin/patches/patch-bk20
6 files changed, 0 insertions, 274 deletions
diff --git a/mail/spamassassin/patches/patch-bf b/mail/spamassassin/patches/patch-bf
deleted file mode 100644
index bed88654c71..00000000000
--- a/mail/spamassassin/patches/patch-bf
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-bf,v 1.2 2010/10/04 22:12:06 pettai Exp $
-
- fixes spamassassin bug #6392 (running spamassassin 3.3.1 on perl 5.12.x)
- https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6392
-
---- ./lib/Mail/SpamAssassin/Dns.pm.orig 2010-10-01 20:52:41.000000000 +0000
-+++ ./lib/Mail/SpamAssassin/Dns.pm
-@@ -754,7 +754,7 @@ sub enter_helper_run_mode {
- dbg("dns: entering helper-app run mode");
- $self->{old_slash} = $/; # Razor pollutes this
- %{$self->{old_env}} = ();
-- if ( defined %ENV ) {
-+ if ( %ENV ) {
- # undefined values in %ENV can result due to autovivification elsewhere,
- # this prevents later possible warnings when we restore %ENV
- while (my ($key, $value) = each %ENV) {
diff --git a/mail/spamassassin/patches/patch-bg b/mail/spamassassin/patches/patch-bg
deleted file mode 100644
index d5d3b7c9c8c..00000000000
--- a/mail/spamassassin/patches/patch-bg
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-bg,v 1.2 2010/10/04 22:12:06 pettai Exp $
-
- fixes spamassassin bug #6392 (running spamassassin 3.3.1 on perl 5.12.x)
- https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6392
-
---- ./lib/Mail/SpamAssassin/Plugin/BodyEval.pm.orig 2010-03-16 14:49:21.000000000 +0000
-+++ ./lib/Mail/SpamAssassin/Plugin/BodyEval.pm
-@@ -119,7 +119,7 @@ sub _multipart_alternative_difference {
- }
-
- # If there are no words, mark if there's at least 1 image ...
-- if (keys %html == 0 && exists $pms->{html}{inside}{img}) {
-+ if (!%html && exists $pms->{html}{inside}{img}) {
- # Use "\n" as the mark since it can't ever occur normally
- $html{"\n"}=1;
- }
diff --git a/mail/spamassassin/patches/patch-bh b/mail/spamassassin/patches/patch-bh
deleted file mode 100644
index 4393f30446a..00000000000
--- a/mail/spamassassin/patches/patch-bh
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-bh,v 1.2 2010/10/04 22:12:06 pettai Exp $
-
- fixes spamassassin bug #6392 (running spamassassin 3.3.1 on perl 5.12.x)
- https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6392
-
---- ./lib/Mail/SpamAssassin/HTML.pm.orig 2010-10-01 20:58:44.000000000 +0000
-+++ ./lib/Mail/SpamAssassin/HTML.pm
-@@ -191,7 +191,7 @@ sub get_rendered_text {
- my $self = shift;
- my %options = @_;
-
-- return join('', @{ $self->{text} }) unless keys %options;
-+ return join('', @{ $self->{text} }) unless %options;
-
- my $mask;
- while (my ($k, $v) = each %options) {
diff --git a/mail/spamassassin/patches/patch-bi b/mail/spamassassin/patches/patch-bi
deleted file mode 100644
index a665b25a3b9..00000000000
--- a/mail/spamassassin/patches/patch-bi
+++ /dev/null
@@ -1,190 +0,0 @@
-$NetBSD: patch-bi,v 1.2 2010/10/04 22:12:06 pettai Exp $
-
- fixes spamassassin bug #6392 (running spamassassin 3.3.1 on perl 5.12.x)
- https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6392
-
---- ./lib/Mail/SpamAssassin/Plugin/Check.pm.orig 2010-03-16 14:49:21.000000000 +0000
-+++ ./lib/Mail/SpamAssassin/Plugin/Check.pm
-@@ -307,64 +307,51 @@ sub run_generic_tests {
- my $package_name = __PACKAGE__;
- my $methodname = $package_name."::_".$ruletype."_tests_".$clean_priority;
-
-- if (defined &{$methodname} && !$doing_user_rules) {
--run_compiled_method:
-- # dbg("rules: run_generic_tests - calling %s", $methodname);
-- my $t = Mail::SpamAssassin::Timeout->new({ deadline => $master_deadline });
-- my $err = $t->run(sub {
-- no strict "refs";
-- $methodname->($pms, @{$opts{args}});
-- });
-- if ($t->timed_out() && $master_deadline && time > $master_deadline) {
-- info("check: exceeded time limit in $methodname, skipping further tests");
-- $pms->{deadline_exceeded} = 1;
-- }
-- return;
-- }
-+ if (!defined &{$methodname} || $doing_user_rules) {
-
-- # use %nopts for named parameter-passing; it's more friendly to future-proof
-- # subclassing, since new parameters can be added without breaking third-party
-- # subclassed implementations of this plugin.
-- my %nopts = (
-- ruletype => $ruletype,
-- doing_user_rules => $doing_user_rules,
-- priority => $priority,
-- clean_priority => $clean_priority
-- );
-+ # use %nopts for named parameter-passing; it's more friendly
-+ # to future-proof subclassing, since new parameters can be added without
-+ # breaking third-party subclassed implementations of this plugin.
-+ my %nopts = (
-+ ruletype => $ruletype,
-+ doing_user_rules => $doing_user_rules,
-+ priority => $priority,
-+ clean_priority => $clean_priority
-+ );
-+
-+ # build up the eval string...
-+ $self->{evalstr_methodname} = $methodname;
-+ $self->{evalstr_chunk_current_methodname} = undef;
-+ $self->{evalstr_chunk_methodnames} = [];
-+ $self->{evalstr_chunk_prefix} = []; # stack (array) of source code sections
-+ $self->{evalstr} = ''; $self->{evalstr_l} = 0;
-+ $self->{evalstr2} = '';
-+ $self->begin_evalstr_chunk($pms);
-
-- # build up the eval string...
-- $self->{evalstr_methodname} = $methodname;
-- $self->{evalstr_chunk_current_methodname} = undef;
-- $self->{evalstr_chunk_methodnames} = [];
-- $self->{evalstr_chunk_prefix} = []; # stack (array) of source code sections
-- $self->{evalstr} = ''; $self->{evalstr_l} = 0;
-- $self->{evalstr2} = '';
-- $self->begin_evalstr_chunk($pms);
--
-- $self->push_evalstr_prefix($pms, '
-- # start_rules_plugin_code '.$ruletype.' '.$priority.'
-- my $scoresptr = $self->{conf}->{scores};
-- ');
-- if (defined $opts{pre_loop_body}) {
-- $opts{pre_loop_body}->($self, $pms, $conf, %nopts);
-- }
-- $self->add_evalstr($pms,
-- $self->start_rules_plugin_code($ruletype, $priority) );
-- while (my($rulename, $test) = each %{$opts{testhash}->{$priority}}) {
-- $opts{loop_body}->($self, $pms, $conf, $rulename, $test, %nopts);
-- }
-- if (defined $opts{post_loop_body}) {
-- $opts{post_loop_body}->($self, $pms, $conf, %nopts);
-- }
-+ $self->push_evalstr_prefix($pms, '
-+ # start_rules_plugin_code '.$ruletype.' '.$priority.'
-+ my $scoresptr = $self->{conf}->{scores};
-+ ');
-+ if (defined $opts{pre_loop_body}) {
-+ $opts{pre_loop_body}->($self, $pms, $conf, %nopts);
-+ }
-+ $self->add_evalstr($pms,
-+ $self->start_rules_plugin_code($ruletype, $priority) );
-+ while (my($rulename, $test) = each %{$opts{testhash}->{$priority}}) {
-+ $opts{loop_body}->($self, $pms, $conf, $rulename, $test, %nopts);
-+ }
-+ if (defined $opts{post_loop_body}) {
-+ $opts{post_loop_body}->($self, $pms, $conf, %nopts);
-+ }
-
-- $self->flush_evalstr($pms, 'run_generic_tests');
-- $self->free_ruleset_source($pms, $ruletype, $priority);
-+ $self->flush_evalstr($pms, 'run_generic_tests');
-+ $self->free_ruleset_source($pms, $ruletype, $priority);
-
-- # clear out a previous version of this method
-- undef &{$methodname};
-+ # clear out a previous version of this method
-+ undef &{$methodname};
-
-- # generate the loop that goes through each line...
-- my $evalstr = <<"EOT";
-+ # generate the loop that goes through each line...
-+ my $evalstr = <<"EOT";
- {
- package $package_name;
-
-@@ -373,40 +360,51 @@ run_compiled_method:
- sub $methodname {
- EOT
-
-- for my $chunk_methodname (@{$self->{evalstr_chunk_methodnames}}) {
-- $evalstr .= " $chunk_methodname(\@_);\n";
-- }
-+ for my $chunk_methodname (@{$self->{evalstr_chunk_methodnames}}) {
-+ $evalstr .= " $chunk_methodname(\@_);\n";
-+ }
-
-- $evalstr .= <<"EOT";
-+ $evalstr .= <<"EOT";
- }
-
- 1;
- }
- EOT
-
-- delete $self->{evalstr}; # free up some RAM before we eval()
-- delete $self->{evalstr2};
-- delete $self->{evalstr_methodname};
-- delete $self->{evalstr_chunk_current_methodname};
-- delete $self->{evalstr_chunk_methodnames};
-- delete $self->{evalstr_chunk_prefix};
--
-- dbg("rules: run_generic_tests - compiling eval code: %s, priority %s",
-- $ruletype, $priority);
--# dbg("rules: eval code to compile: $evalstr");
-- my $eval_result;
-- { my $timer = $self->{main}->time_method('compile_gen');
-- $eval_result = eval($evalstr);
-- }
-- if (!$eval_result) {
-- my $eval_stat = $@ ne '' ? $@ : "errno=$!"; chomp $eval_stat;
-- warn "rules: failed to compile $ruletype tests, skipping:\n".
-- "\t($eval_stat)\n";
-- $pms->{rule_errors}++;
-- }
-- else {
-+ delete $self->{evalstr}; # free up some RAM before we eval()
-+ delete $self->{evalstr2};
-+ delete $self->{evalstr_methodname};
-+ delete $self->{evalstr_chunk_current_methodname};
-+ delete $self->{evalstr_chunk_methodnames};
-+ delete $self->{evalstr_chunk_prefix};
-+
-+ dbg("rules: run_generic_tests - compiling eval code: %s, priority %s",
-+ $ruletype, $priority);
-+ # dbg("rules: eval code to compile: $evalstr");
-+ my $eval_result;
-+ { my $timer = $self->{main}->time_method('compile_gen');
-+ $eval_result = eval($evalstr);
-+ }
-+ if (!$eval_result) {
-+ my $eval_stat = $@ ne '' ? $@ : "errno=$!"; chomp $eval_stat;
-+ warn "rules: failed to compile $ruletype tests, skipping:\n".
-+ "\t($eval_stat)\n";
-+ $pms->{rule_errors}++;
-+ return;
-+ }
- dbg("rules: compiled $ruletype tests");
-- goto run_compiled_method;
-+ }
-+
-+#run_compiled_method:
-+# dbg("rules: run_generic_tests - calling %s", $methodname);
-+ my $t = Mail::SpamAssassin::Timeout->new({ deadline => $master_deadline });
-+ my $err = $t->run(sub {
-+ no strict "refs";
-+ $methodname->($pms, @{$opts{args}});
-+ });
-+ if ($t->timed_out() && $master_deadline && time > $master_deadline) {
-+ info("check: exceeded time limit in $methodname, skipping further tests");
-+ $pms->{deadline_exceeded} = 1;
- }
- }
-
diff --git a/mail/spamassassin/patches/patch-bj b/mail/spamassassin/patches/patch-bj
deleted file mode 100644
index b4b111eaec2..00000000000
--- a/mail/spamassassin/patches/patch-bj
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-bj,v 1.2 2010/10/04 22:12:06 pettai Exp $
-
- fixes spamassassin bug #6396 (perl 5.12.x and spamassassin 3.3.1)
- https://issues.apache.org/SpamAssassin/show_bug.cgi?id=6396
-
---- lib/Mail/SpamAssassin/Plugin/MIMEEval.pm.orig 2010-03-16 14:49:21.000000000 +0000
-+++ lib/Mail/SpamAssassin/Plugin/MIMEEval.pm
-@@ -498,7 +498,7 @@ sub _check_base64_length {
- # perhaps just limit to test, and image?
- next if ($ctype eq 'application/ics');
-
-- my $cte = lc $p->get_header('content-transfer-encoding') || '';
-+ my $cte = lc($p->get_header('content-transfer-encoding') || '');
- next if ($cte !~ /^base64$/);
- foreach my $l ( @{$p->raw()} ) {
- my $len = length $l;
diff --git a/mail/spamassassin/patches/patch-bk b/mail/spamassassin/patches/patch-bk
deleted file mode 100644
index 17f8661d5fd..00000000000
--- a/mail/spamassassin/patches/patch-bk
+++ /dev/null
@@ -1,20 +0,0 @@
-$NetBSD: patch-bk,v 1.1 2010/10/06 21:27:30 pettai Exp $
-
- fixes "Use of uninitialized value $opt{"syslog-socket"} in lc" error
-
---- spamd/spamd.raw.orig 2010-03-16 14:49:25.000000000 +0000
-+++ spamd/spamd.raw
-@@ -443,10 +443,12 @@ my $log_facility = $opt{'syslog'} || 'ma
- # socket of 'none' means as much as --syslog=null. Sounds complicated? It is.
- # But it works.
- # )
--my $log_socket = lc($opt{'syslog-socket'});
-+my $log_socket = $opt{'syslog-socket'};
-
- if (!defined $log_socket || $log_socket eq '') {
- $log_socket = am_running_on_windows() ? 'none' : 'unix';
-+} else {
-+ $log_socket = lc $log_socket;
- }
-
- # This is the default log file; it can be changed on the command line