Gnus development mailing list
 help / color / mirror / Atom feed
* patch: bug in gnus-mlspl.el re generation of restrict clauses
@ 2001-06-03 20:49 Dale Hagglund
  2001-06-07 23:24 ` ShengHuo ZHU
  0 siblings, 1 reply; 2+ messages in thread
From: Dale Hagglund @ 2001-06-03 20:49 UTC (permalink / raw)
  Cc: larsi

I just upgraded to ognus-0.03 after a long time of using gnus 5.8.3.
Right away, I ran across a bug in the generation of restrict clauses
from the "split-exclude" group property.  The code I fixed was
introduced on 29 November 2000, in revision 5.8 of gnus-mlspl.el.

Basically, the current code only worked for a split-exclude of the
form

        (split-exclude . STRING)

and not for anything of the form

        (split-exclude STRING [STRING...])

which is what I'd used in my group parameters.

My split-excludes worked for me in 5.8.3, so I checked the cvs diffs.
In the change from rev 5.7 to 5.8 of this file, use of mapcon was
deleted for some reason.  However even this older code doesn't work if
there are two or more strings given in the split-exclude property.

I've attached a patch for gnus-mlspl.el, and a corresponding ChangeLog
entry.  The patches are relative to the 3 June 20:45 GMT 2001 version
state of the cvs repository.

Please let me know if this isn't the correct venue for mailing
patches.

Dale.

Index: ChangeLog
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/ChangeLog,v
retrieving revision 6.441
diff -u -r6.441 ChangeLog
--- ChangeLog   2001/06/01 20:57:07     6.441
+++ ChangeLog   2001/06/02 20:30:08
@@ -1,3 +1,8 @@
+2001-06-03  Dale Hagglund  <rdh@best.com>
+
+       * gnus-mlspl.el (gnus-group-split-fancy): fix generation of split
+       restrict clauses.
+
 2001-06-02  Simon Josefsson  <simon@josefsson.org>
 
        * imap.el (imap-kerberos4-open): 
Index: gnus-mlspl.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-mlspl.el,v
retrieving revision 6.1
diff -u -r6.1 gnus-mlspl.el
--- gnus-mlspl.el       2000/11/07 03:27:15     6.1
+++ gnus-mlspl.el       2001/06/02 20:30:08
@@ -196,12 +196,9 @@
                         (list 'any split-regexp)
                         ;; Generate RESTRICTs for SPLIT-EXCLUDEs.
                         (if (listp split-exclude)
-                            (let ((seq split-exclude)
-                                  res)
-                              (while seq
-                                (push (cons '- (pop seq))
-                                      res))
-                              (apply #'nconc (nreverse res)))
+                            (apply #'append 
+                                   (mapcar (lambda (arg) (list '- arg))
+                                           split-exclude))
                           (list '- split-exclude))
                         (list group-clean))
                        split)


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: patch: bug in gnus-mlspl.el re generation of restrict clauses
  2001-06-03 20:49 patch: bug in gnus-mlspl.el re generation of restrict clauses Dale Hagglund
@ 2001-06-07 23:24 ` ShengHuo ZHU
  0 siblings, 0 replies; 2+ messages in thread
From: ShengHuo ZHU @ 2001-06-07 23:24 UTC (permalink / raw)
  Cc: Dale Hagglund

Dale Hagglund <rdh@best.com> writes:

[...]

> 
> Index: ChangeLog
> ===================================================================
> RCS file: /usr/local/cvsroot/gnus/lisp/ChangeLog,v
> retrieving revision 6.441
> diff -u -r6.441 ChangeLog
> --- ChangeLog   2001/06/01 20:57:07     6.441
>+++ ChangeLog   2001/06/02 20:30:08
> @@ -1,3 +1,8 @@
>+2001-06-03  Dale Hagglund  <rdh@best.com>
>+
>+       * gnus-mlspl.el (gnus-group-split-fancy): fix generation of split
>+       restrict clauses.
>+

Thanks for the patch. I've installed it.

ShengHuo


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2001-06-07 23:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-03 20:49 patch: bug in gnus-mlspl.el re generation of restrict clauses Dale Hagglund
2001-06-07 23:24 ` ShengHuo ZHU

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).