X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lisp%2Fnnsoup.el;h=ed457ea76154b15b3f6d9b12436af25801ba0b8b;hb=0a919ac2e96918074f11c8740a5acadbec21a676;hp=d39c999e613199c5337e5ad02a8a14a32d8a6188;hpb=06aa1b92759389956224a3116e4d3655e5118670;p=elisp%2Fgnus.git- diff --git a/lisp/nnsoup.el b/lisp/nnsoup.el index d39c999..ed457ea 100644 --- a/lisp/nnsoup.el +++ b/lisp/nnsoup.el @@ -557,9 +557,8 @@ backend for the messages.") (defun nnsoup-unpack-packets () "Unpack all packets in `nnsoup-packet-directory'." (let ((packets (directory-files - nnsoup-packet-directory t nnsoup-packet-regexp)) - packet) - (while (setq packet (pop packets)) + nnsoup-packet-directory t nnsoup-packet-regexp))) + (dolist (packet packets) (nnheader-message 5 "nnsoup: unpacking %s..." packet) (if (not (gnus-soup-unpack-packet nnsoup-tmp-directory nnsoup-unpacker packet)) @@ -758,20 +757,18 @@ backend for the messages.") (string-to-int (match-string 1 f2))))))) active group lines ident elem min) (set-buffer (get-buffer-create " *nnsoup work*")) - (while files - (nnheader-message 5 "Doing %s..." (car files)) + (dolist (file files) + (nnheader-message 5 "Doing %s..." file) (erase-buffer) - (nnheader-insert-file-contents (car files)) + (nnheader-insert-file-contents file) (goto-char (point-min)) (if (not (re-search-forward "^[^\t]*\t[^\t]*\t[^\t]*\t[^\t]*\t[^\t]*\t[^\t]*\t[^\t]*\t[^\t]*\t *\\(Xref: \\)? *[^ ]* \\([^ ]+\\):[0-9]" nil t)) (setq group "unknown") (setq group (match-string 2))) (setq lines (count-lines (point-min) (point-max))) (setq ident (progn (string-match - "/\\([0-9]+\\)\\." (car files)) - (substring - (car files) (match-beginning 1) - (match-end 1)))) + "/\\([0-9]+\\)\\." file) + (match-string 1 file))) (if (not (setq elem (assoc group active))) (push (list group (cons 1 lines) (list (cons 1 lines) @@ -782,8 +779,7 @@ backend for the messages.") (list (cons (1+ (setq min (cdadr elem))) (+ min lines)) (vector ident group "ucm" "" lines)))) - (setcdr (cadr elem) (+ min lines))) - (setq files (cdr files))) + (setcdr (cadr elem) (+ min lines)))) (nnheader-message 5 "") (setq nnsoup-group-alist active) (nnsoup-write-active-file t))) @@ -800,9 +796,9 @@ backend for the messages.") nnsoup-group-alist))) (regexp "\\.MSG$\\|\\.IDX$") (files (directory-files nnsoup-directory nil regexp)) - non-files file) + non-files) ;; Find all files that aren't known by nnsoup. - (while (setq file (pop files)) + (dolist (file files) (string-match regexp file) (unless (member (substring file 0 (match-beginning 0)) known) (push file non-files)))