From 12537409d77b31c7109256b118fe062d284b83fd Mon Sep 17 00:00:00 2001 From: hayashi Date: Wed, 16 Sep 1998 00:20:37 +0000 Subject: [PATCH] Sync up with Gnus 5.6.43 --- lisp/gnus-agent.el | 47 +++++++++++++++++++++++++++-------------------- lisp/gnus-msg.el | 3 +-- lisp/gnus-score.el | 4 ++-- lisp/gnus-srvr.el | 8 +++++--- lisp/gnus-sum.el | 8 ++++++++ lisp/gnus.el | 4 ++-- lisp/nnheader.el | 1 - lisp/nnmail.el | 3 ++- texi/gnus-ja.texi | 6 +++--- 9 files changed, 50 insertions(+), 34 deletions(-) diff --git a/lisp/gnus-agent.el b/lisp/gnus-agent.el index c170e7e..7fc3619 100644 --- a/lisp/gnus-agent.el +++ b/lisp/gnus-agent.el @@ -751,17 +751,13 @@ the actual number of articles toggled is returned." (pop gnus-agent-group-alist)))) (defun gnus-agent-fetch-headers (group &optional force) - (gnus-agent-load-alist group) - ;; Find out what headers we need to retrieve. - (when articles - (while (and articles - (assq (car articles) gnus-agent-article-alist)) - (pop articles)) - (let ((arts articles)) - (while (cdr arts) - (if (assq (cadr arts) gnus-agent-article-alist) - (setcdr arts (cddr arts)) - (setq arts (cdr arts))))) + (let ((articles (if (gnus-agent-load-alist group) + (gnus-sorted-intersection + (gnus-list-of-unread-articles group) + (gnus-uncompress-range + (cons (1+ (caar (last gnus-agent-article-alist))) + (cdr (gnus-active group))))) + (gnus-list-of-unread-articles group)))) ;; Fetch them. (when articles (gnus-message 7 "Fetching headers for %s..." group) @@ -779,11 +775,11 @@ the actual number of articles toggled is returned." (file-name-directory file))) (write-region (point-min) (point-max) file nil 'silent) (gnus-agent-save-alist group articles nil) - (gnus-agent-enter-history "last-header-fetched-for-session" - (list (cons group (nth (- (length articles) 1) articles))) - (gnus-time-to-day (current-time))) - t))))) - + (gnus-agent-enter-history + "last-header-fetched-for-session" + (list (cons group (nth (- (length articles) 1) articles))) + (gnus-time-to-day (current-time))) + articles))))) (defsubst gnus-agent-copy-nov-line (article) (let (b e) @@ -1353,7 +1349,8 @@ The following commands are available: (sort gnus-agent-article-alist 'car-less-than-car)) (let* ((alist gnus-agent-article-alist) (prev (cons nil alist)) - (first prev)) + (first prev) + expired) (while (and alist (<= (caar alist) article)) (if (or (not (cdar alist)) @@ -1362,7 +1359,9 @@ The following commands are available: (number-to-string (caar alist)) group)))) - (setcdr prev (setq alist (cdr alist))) + (progn + (push (caar alist) expired) + (setcdr prev (setq alist (cdr alist)))) (setq prev alist alist (cdr alist)))) (setq gnus-agent-article-alist (cdr first)) @@ -1373,11 +1372,19 @@ The following commands are available: (gnus-range-add (nth 2 info) (cons 1 (- (caar gnus-agent-article-alist) 1))))) + ;; Maybe everything has been expired from `gnus-article-alist' + ;; and so the above marking as read could not be conducted, + ;; or there are expired article within the range of the alist. + (when (or (not (caar gnus-agent-article-alist)) + (> (car expired) (caar gnus-agent-article-alist))) + (setcar (nthcdr 2 info) + (gnus-add-to-range + (nth 2 info) + (nreverse expired)))) (gnus-dribble-enter (concat "(gnus-group-set-info '" (gnus-prin1-to-string info) - ")")) - (gnus-agent-save-alist group))) + ")")))) expiry-hashtb) (set-buffer history) (setq histories (nreverse (sort histories '<))) diff --git a/lisp/gnus-msg.el b/lisp/gnus-msg.el index 32ebcf4..29943ae 100644 --- a/lisp/gnus-msg.el +++ b/lisp/gnus-msg.el @@ -556,8 +556,7 @@ automatically." ;; Stripping headers should be specified with mail-yank-ignored-headers. (when yank (gnus-summary-goto-subject (car yank))) - (let ((gnus-article-reply t) - (gnus-inhibit-posting-styles t)) + (let ((gnus-article-reply t)) (gnus-setup-message (if yank 'reply-yank 'reply) (gnus-summary-select-article) (set-buffer (gnus-copy-article-buffer)) diff --git a/lisp/gnus-score.el b/lisp/gnus-score.el index 8cff072..c429950 100644 --- a/lisp/gnus-score.el +++ b/lisp/gnus-score.el @@ -505,7 +505,7 @@ used as score." (?l "lines" nil nil number) (?d "date" nil nil date) (?f "followup" nil nil string) - (?t "thread" nil nil string))) + (?t "thread" "message-id" nil string))) (char-to-type '((?s s "substring" string) (?e e "exact string" string) @@ -591,7 +591,7 @@ used as score." ;; It was a majuscule, so we end reading and use the default. (if mimic (message "%c %c %c" prefix hchar tchar) (message "")) - (setq pchar (or pchar ?p))) + (setq pchar (or pchar ?t))) ;; We continue reading. (while (not pchar) diff --git a/lisp/gnus-srvr.el b/lisp/gnus-srvr.el index ffe5533..21abf17 100644 --- a/lisp/gnus-srvr.el +++ b/lisp/gnus-srvr.el @@ -592,9 +592,11 @@ The following commands are available: (while (re-search-forward "\\(^[^ \t]+\\)[ \t]+[0-9]+[ \t]+[0-9]+" nil t) (goto-char (match-end 1)) - (push (cons (match-string 1) - (max 0 (- (1+ (read cur)) (read cur)))) - groups)))) + (condition-case () + (push (cons (match-string 1) + (max 0 (- (1+ (read cur)) (read cur)))) + groups) + (error nil))))) (setq groups (sort groups (lambda (l1 l2) (string< (car l1) (car l2))))) diff --git a/lisp/gnus-sum.el b/lisp/gnus-sum.el index 816080f..a221ba7 100644 --- a/lisp/gnus-sum.el +++ b/lisp/gnus-sum.el @@ -2046,6 +2046,7 @@ The following commands are available: (let ((data gnus-newsgroup-data)) (save-excursion (gnus-save-hidden-threads + (gnus-summary-show-all-threads) (goto-char (point-min)) (while data (while (get-text-property (point) 'gnus-intangible) @@ -3398,6 +3399,7 @@ If LINE, insert the rebuilt thread starting on line LINE." (while thread (gnus-remove-thread-1 (car thread)) (setq thread (cdr thread)))) + (gnus-summary-show-all-threads) (gnus-remove-thread-1 thread)))))))) (defun gnus-remove-thread-1 (thread) @@ -7668,6 +7670,8 @@ returned." (= mark gnus-read-mark) (= mark gnus-souped-mark) (= mark gnus-duplicate-mark))) (setq mark gnus-expirable-mark) + ;; Let the backend know about the mark change. + (setq mark (gnus-request-update-mark gnus-newsgroup-name article mark)) (push article gnus-newsgroup-expirable)) ;; Set the mark in the buffer. (gnus-summary-update-mark mark 'unread) @@ -7677,6 +7681,8 @@ returned." "Mark the current article quickly as unread with MARK." (let* ((article (gnus-summary-article-number)) (old-mark (gnus-summary-article-mark article))) + ;; Let the backend know about the mark change. + (setq mark (gnus-request-update-mark gnus-newsgroup-name article mark)) (if (eq mark old-mark) t (if (<= article 0) @@ -7732,6 +7738,8 @@ marked." (let* ((mark (or mark gnus-del-mark)) (article (or article (gnus-summary-article-number))) (old-mark (gnus-summary-article-mark article))) + ;; Let the backend know about the mark change. + (setq mark (gnus-request-update-mark gnus-newsgroup-name article mark)) (if (eq mark old-mark) t (unless article diff --git a/lisp/gnus.el b/lisp/gnus.el index edfd36d..c4edf17 100644 --- a/lisp/gnus.el +++ b/lisp/gnus.el @@ -1663,8 +1663,8 @@ gnus-newsrc-hashtb should be kept so that both hold the same information.") gnus-post-news gnus-summary-reply gnus-summary-reply-with-original gnus-summary-mail-forward gnus-summary-mail-other-window gnus-summary-resend-message gnus-summary-resend-bounced-mail - gnus-summary-wide-reply - gnus-bug) + gnus-summary-wide-reply gnus-summary-followup-to-mail + gnus-summary-followup-to-mail-with-original gnus-bug) ("gnus-picon" :interactive t gnus-article-display-picons gnus-group-display-picons gnus-picons-article-display-x-face gnus-picons-display-x-face) diff --git a/lisp/nnheader.el b/lisp/nnheader.el index e0de0a4..bc725b6 100644 --- a/lisp/nnheader.el +++ b/lisp/nnheader.el @@ -400,7 +400,6 @@ the line could be found." (unless (gnus-buffer-live-p nntp-server-buffer) (setq nntp-server-buffer (get-buffer-create " *nntpd*"))) (set-buffer nntp-server-buffer) - (buffer-disable-undo (current-buffer)) (erase-buffer) (kill-all-local-variables) (setq case-fold-search t) ;Should ignore case. diff --git a/lisp/nnmail.el b/lisp/nnmail.el index bc8d1f5..16541b1 100644 --- a/lisp/nnmail.el +++ b/lisp/nnmail.el @@ -532,7 +532,8 @@ parameter. It should return nil, `warn' or `delete'." (aref t1 2) (aref t1 1) (aref t1 0) (aref d1 2) (aref d1 1) (aref d1 0) (number-to-string - (* 60 (timezone-zone-to-minute (aref d1 4)))))))) + (* 60 (timezone-zone-to-minute + (or (aref d1 4) (current-time-zone))))))))) ;; If we get an error, then we just return a 0 time. (error (list 0 0)))) diff --git a/texi/gnus-ja.texi b/texi/gnus-ja.texi index 91a525a..9dacb61 100644 --- a/texi/gnus-ja.texi +++ b/texi/gnus-ja.texi @@ -12754,9 +12754,9 @@ line)} に設定してください。 @lisp (setq gnus-home-score-file ;; All groups that match the regexp "\\.emacs" - '("\\.emacs" "emacs.SCORE") - ;; All the comp groups in one score file - ("^comp" "comp.SCORE")) + '(("\\.emacs" "emacs.SCORE") + ;; All the comp groups in one score file + ("^comp" "comp.SCORE"))) @end lisp @vindex gnus-home-adapt-file -- 1.7.10.4