From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/61962 Path: news.gmane.org!not-for-mail From: "Ted Zlatanov" Newsgroups: gmane.emacs.gnus.general Subject: Re: spam-check-spamassassin-headers with spamassasin 3.0/3.1 Date: 13 Feb 2006 11:42:02 -0500 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <4nwtfzus6d.fsf@lifelogs.com> References: <873biqwtf5.fsf@puyo.nijino.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1139848978 32319 80.91.229.2 (13 Feb 2006 16:42:58 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 13 Feb 2006 16:42:58 +0000 (UTC) Cc: "Ding Mailing List" Original-X-From: ding-owner+m10489@lists.math.uh.edu Mon Feb 13 17:42:56 2006 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by ciao.gmane.org with esmtp (Exim 4.43) id 1F8gmV-000717-TP for ding-account@gmane.org; Mon, 13 Feb 2006 17:42:32 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu ident=lists) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 1F8gmR-0008DK-00; Mon, 13 Feb 2006 10:42:27 -0600 Original-Received: from nas01.math.uh.edu ([129.7.128.39]) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 1F8gmA-0008DF-00 for ding@lists.math.uh.edu; Mon, 13 Feb 2006 10:42:10 -0600 Original-Received: from quimby.gnus.org ([80.91.224.244]) by nas01.math.uh.edu with esmtp (Exim 4.52) id 1F8gm8-0003Kj-3t for ding@lists.math.uh.edu; Mon, 13 Feb 2006 10:42:10 -0600 Original-Received: from clifford.bwh.harvard.edu ([134.174.9.41] helo=mail.bwh.harvard.edu) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1F8gm6-00068O-00 for ; Mon, 13 Feb 2006 17:42:07 +0100 Original-Received: (qmail 15873 invoked from network); 13 Feb 2006 16:35:23 -0000 Envelope-Sender: tzz@lifelogs.com Envelope-Recipients: ari@mbf.ocn.ne.jp, ding@gnus.org, Original-Received: from asimov.bwh.harvard.edu (HELO asimov) ([134.174.8.118]) (envelope-sender ) by mail.bwh.harvard.edu (qmail-ldap-1.03) with SMTP for ; 13 Feb 2006 16:35:23 -0000 Mail-Followup-To: "ARISAWA Akihiro" , "Ding Mailing List " Original-To: "ARISAWA Akihiro" X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6;d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" X-Hashcash: 1:20:060213:ari@mbf.ocn.ne.jp::abiN9xXqvBiZQ8nm:000000000 000000000000000000000000000000000004gGE X-Hashcash: 1:20:060213:ding@gnus.org::xTWWRYkmu4cwtEBr:000007MV In-Reply-To: <873biqwtf5.fsf@puyo.nijino.com> (ARISAWA Akihiro's message of "Sat, 11 Feb 2006 10:55:26 +0900") User-Agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux) X-Spam-Score: -2.6 (--) Precedence: bulk Original-Sender: ding-owner@lists.math.uh.edu Xref: news.gmane.org gmane.emacs.gnus.general:61962 Archived-At: On 10 Feb 2006, ari@mbf.ocn.ne.jp wrote: > Hi, > > I am using spamassassin 3.1, and (setq spam-use-spamassassin-headers t). > When I typed S t in Summary buffer, reported score is always 0. > > Spamassassin 3.0 or later, the default X-Spam-Status field is changed as: >> X-Spam-Status: No, score=0.1 required=8.0 ... > But, `spam-check-spamassassin-headers' checks only "hits=". > cf. http://issues.apache.org/SpamAssassin/show_bug.cgi?id=1332 > > When I changed spam.el as attached, the reported score is corrected. > > Regards, > ARISAWA Akihiro > 2006-02-11 ARISAWA Akihiro > > * spam.el (spam-check-spamassassin-headers): Improved regexp > for spamassassin 3.0 or later. > > Index: lisp/spam.el > =================================================================== > RCS file: /usr/local/cvsroot/gnus/lisp/spam.el,v > retrieving revision 7.77 > diff -u -r7.77 spam.el > --- lisp/spam.el 8 Feb 2006 04:17:15 -0000 7.77 > +++ lisp/spam.el 11 Feb 2006 01:35:11 -0000 > @@ -2614,8 +2614,8 @@ > (if score ; scoring mode > (let ((header (message-fetch-field spam-spamassassin-spam-status-header))) > (when header > - (if (string-match "hits=\\(-?[0-9.]+\\)" header) > - (match-string 1 header) > + (if (string-match "\\(hits\\|score\\)=\\(-?[0-9.]+\\)" header) > + (match-string 2 header) > "0"))) > ;; spam detection mode > (let ((header (message-fetch-field spam-spamassassin-spam-flag-header))) Thanks! Can someone else on ding with SA 3.x test this patch please? I'll commit it as soon as I get a confirmation. Ted