projects
/
elisp
/
gnus.git-
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Synch to Gnus 200308070200.
[elisp/gnus.git-]
/
lisp
/
nnspool.el
diff --git
a/lisp/nnspool.el
b/lisp/nnspool.el
index
2208af7
..
add0e7e
100644
(file)
--- a/
lisp/nnspool.el
+++ b/
lisp/nnspool.el
@@
-1,8
+1,11
@@
;;; nnspool.el --- spool access for GNU Emacs
;;; nnspool.el --- spool access for GNU Emacs
-;; Copyright (C) 198,998,89,90,93,94,95,96,97,98 Free Software Foundation, Inc.
+
+;; Copyright (C) 1988, 1989, 1990, 1993, 1994, 1995, 1996, 1997, 1998,
+;; 2000, 2002, 2003
+;; Free Software Foundation, Inc.
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
;; Author: Masanobu UMEDA <umerin@flab.flab.fujitsu.junet>
-;; Lars Magne Ingebrigtsen <larsi@gnus.org>
+;; Lars Magne Ingebrigtsen <larsi@gnus.org>
;; Keywords: news
;; This file is part of GNU Emacs.
;; Keywords: news
;; This file is part of GNU Emacs.
@@
-26,10
+29,12
@@
;;; Code:
;;; Code:
+(eval-when-compile (require 'cl))
+(eval-when-compile (require 'gnus-clfns))
+
(require 'nnheader)
(require 'nntp)
(require 'nnoo)
(require 'nnheader)
(require 'nntp)
(require 'nnoo)
-(eval-when-compile (require 'cl))
(nnoo-declare nnspool)
(nnoo-declare nnspool)
@@
-47,7
+52,10
@@
If you are using Cnews, you probably should set this variable to nil.")
(defvoo nnspool-nov-directory (concat nnspool-spool-directory "over.view/")
"Local news nov directory.")
(defvoo nnspool-nov-directory (concat nnspool-spool-directory "over.view/")
"Local news nov directory.")
-(defvoo nnspool-lib-dir "/usr/lib/news/"
+(defvoo nnspool-lib-dir
+ (if (file-exists-p "/usr/lib/news/active")
+ "/usr/lib/news/"
+ "/var/lib/news/")
"Where the local news library files are stored.")
(defvoo nnspool-active-file (concat nnspool-lib-dir "active")
"Where the local news library files are stored.")
(defvoo nnspool-active-file (concat nnspool-lib-dir "active")
@@
-66,8
+74,8
@@
If you are using Cnews, you probably should set this variable to nil.")
"Local news active date file.")
(defvoo nnspool-large-newsgroup 50
"Local news active date file.")
(defvoo nnspool-large-newsgroup 50
- "The number of the articles which indicates a large newsgroup.
-If the number of the articles is greater than the value, verbose
+ "The number of articles which indicates a large newsgroup.
+If the number of articles is greater than the value, verbose
messages will be shown to indicate the current status.")
(defvoo nnspool-nov-is-evil nil
messages will be shown to indicate the current status.")
(defvoo nnspool-nov-is-evil nil
@@
-148,7
+156,7
@@
there.")
(and do-message
(zerop (% (incf count) 20))
(nnheader-message 5 "nnspool: Receiving headers... %d%%"
(and do-message
(zerop (% (incf count) 20))
(nnheader-message 5 "nnspool: Receiving headers... %d%%"
- (/ (* count 100) number))))
+ (/ (* count 100) number))))
(when do-message
(nnheader-message 5 "nnspool: Receiving headers...done"))
(when do-message
(nnheader-message 5 "nnspool: Receiving headers...done"))
@@
-298,8
+306,8
@@
there.")
(read (current-buffer)))
seconds))
(push (buffer-substring
(read (current-buffer)))
seconds))
(push (buffer-substring
- (match-beginning 1) (match-end 1))
- groups)
+ (match-beginning 1) (match-end 1))
+ groups)
(zerop (forward-line -1))))
(erase-buffer)
(while groups
(zerop (forward-line -1))))
(erase-buffer)
(while groups
@@
-324,7
+332,8
@@
there.")
()
(nnheader-report 'nnspool "")
(set-process-sentinel proc 'nnspool-inews-sentinel)
()
(nnheader-report 'nnspool "")
(set-process-sentinel proc 'nnspool-inews-sentinel)
- (process-send-region proc (point-min) (point-max))
+ (mm-with-unibyte-current-buffer
+ (process-send-region proc (point-min) (point-max)))
;; We slap a condition-case around this, because the process may
;; have exited already...
(ignore-errors
;; We slap a condition-case around this, because the process may
;; have exited already...
(ignore-errors
@@
-345,8
+354,7
@@
there.")
;; Make status message by folding lines.
(while (re-search-forward "[ \t\n]+" nil t)
(replace-match " " t t))
;; Make status message by folding lines.
(while (re-search-forward "[ \t\n]+" nil t)
(replace-match " " t t))
- (nnheader-report 'nnspool "%s" (buffer-substring
- (point-min) (point-max)))
+ (nnheader-report 'nnspool "%s" (buffer-string))
(nnheader-message 5 "nnspool: %s" nnspool-status-string)
(ding)
(run-hooks 'nnspool-rejected-article-hook))))
(nnheader-message 5 "nnspool: %s" nnspool-status-string)
(ding)
(run-hooks 'nnspool-rejected-article-hook))))
@@
-357,7
+365,7
@@
there.")
(let ((nov (nnheader-group-pathname
nnspool-current-group nnspool-nov-directory ".overview"))
(arts articles)
(let ((nov (nnheader-group-pathname
nnspool-current-group nnspool-nov-directory ".overview"))
(arts articles)
- (nnheader-file-coding-system nnspool-file-coding-system)
+ (nnheader-file-coding-system nnspool-file-coding-system)
last)
(if (not (file-exists-p nov))
()
last)
(if (not (file-exists-p nov))
()
@@
-453,7
+461,7
@@
there.")
(nnheader-report 'nnspool "No such newsgroup: %s" group)))))
(defun nnspool-article-pathname (group &optional article)
(nnheader-report 'nnspool "No such newsgroup: %s" group)))))
(defun nnspool-article-pathname (group &optional article)
- "Find the path for GROUP."
+ "Find the file name for GROUP."
(nnheader-group-pathname group nnspool-spool-directory article))
(provide 'nnspool)
(nnheader-group-pathname group nnspool-spool-directory article))
(provide 'nnspool)