spamassassin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From quin...@apache.org
Subject svn commit: r151719 - in spamassassin/trunk: lib/Mail/SpamAssassin/HTML.pm rules/70_testing.cf
Date Mon, 07 Feb 2005 08:59:48 GMT
Author: quinlan
Date: Mon Feb  7 00:59:46 2005
New Revision: 151719

URL: http://svn.apache.org/viewcvs?view=rev&rev=151719
Log:
double-closed HTML and BODY tags

Modified:
    spamassassin/trunk/lib/Mail/SpamAssassin/HTML.pm
    spamassassin/trunk/rules/70_testing.cf

Modified: spamassassin/trunk/lib/Mail/SpamAssassin/HTML.pm
URL: http://svn.apache.org/viewcvs/spamassassin/trunk/lib/Mail/SpamAssassin/HTML.pm?view=diff&r1=151718&r2=151719
==============================================================================
--- spamassassin/trunk/lib/Mail/SpamAssassin/HTML.pm (original)
+++ spamassassin/trunk/lib/Mail/SpamAssassin/HTML.pm Mon Feb  7 00:59:46 2005
@@ -134,6 +134,8 @@
   $self->put_results(length => $self->{length});
   $self->put_results(min_size => $self->{min_size});
   $self->put_results(max_size => $self->{max_size});
+  $self->put_results(closed_html => $self->{closed_html});
+  $self->put_results(closed_body => $self->{closed_body});
   if (exists $self->{tags}) {
     $self->put_results(closed_extra_ratio =>
 		       ($self->{closed_extra} / $self->{tags}));
@@ -312,8 +314,8 @@
     }
     # end tags
     else {
-      $self->{closed_html} = 1 if $tag eq "html";
-      $self->{closed_body} = 1 if $tag eq "body";
+      $self->{closed_html}++ if $tag eq "html";
+      $self->{closed_body}++ if $tag eq "body";
     }
   }
 }

Modified: spamassassin/trunk/rules/70_testing.cf
URL: http://svn.apache.org/viewcvs/spamassassin/trunk/rules/70_testing.cf?view=diff&r1=151718&r2=151719
==============================================================================
--- spamassassin/trunk/rules/70_testing.cf (original)
+++ spamassassin/trunk/rules/70_testing.cf Mon Feb  7 00:59:46 2005
@@ -303,3 +303,6 @@
 # simple enough to test
 meta T_RATWARE_SOMETHING	__MSGID_DOLLARS_OK && !__HAS_X_MAILER
 meta T_RATWARE_WHATEVER		__OUTLOOK_DOLLARS_MSGID && !__HAS_X_MAILER
+
+body T_HTML_CLOSED_TWICE	eval:html_eval('closed_html', '> 1')
+body T_BODY_CLOSED_TWICE	eval:html_eval('closed_body', '> 1')



Mime
View raw message