(gnus-namazu/search): Small modified to reduce its spending time.
authortsuchiya <tsuchiya>
Fri, 1 Aug 2003 05:02:35 +0000 (05:02 +0000)
committertsuchiya <tsuchiya>
Fri, 1 Aug 2003 05:02:35 +0000 (05:02 +0000)
ChangeLog
lisp/gnus-namazu.el

index f2c9a23..ab4fe6a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2003-08-01  TSUCHIYA Masatoshi  <tsuchiya@namazu.org>
+
+       * lisp/gnus-namazu.el (gnus-namazu/search): Small modified to
+       reduce its spending time.
+
 2003-07-30  TSUCHIYA Masatoshi  <tsuchiya@namazu.org>
 
        * gnus-namazu.el (gnus-namazu/group-prefixed-name): Removed.
index 6341d6e..ee43a56 100644 (file)
@@ -359,13 +359,17 @@ options make any sense in this context."
        (error "Namazu finished abnormally: %d" exit-status)))
     (gnus-namazu/normalize-results)
     (goto-char (point-min))
-    (let (articles group file)
+    (let (articles group)
       (while (not (eobp))
-       (setq file (buffer-substring-no-properties (point) (gnus-point-at-eol))
-             group (file-name-directory file)
-             file (file-name-nondirectory file))
-       (and (not (string-match "[^0-9]" file))
-            (setq group
+       (setq group (buffer-substring-no-properties
+                    (point)
+                    (progn
+                      (end-of-line)
+                      ;; NOTE: Only numeric characters are permitted
+                      ;; as file names of articles.
+                      (skip-chars-backward "0-9")
+                      (point))))
+       (and (setq group
                   (symbol-value
                    (intern-soft (if gnus-namazu-case-sensitive-filesystem
                                     group
@@ -373,7 +377,11 @@ options make any sense in this context."
                                 (cdr gnus-namazu/directory-table))))
             (or (not groups)
                 (member group groups))
-            (push (gnus-namazu/make-article group (string-to-number file))
+            (push (gnus-namazu/make-article
+                   group
+                   (string-to-number
+                    (buffer-substring-no-properties (point)
+                                                    (gnus-point-at-eol))))
                   articles))
        (forward-line 1))
       (nreverse articles))))