From 1bbbc9816723251cb13b4b9518500a8371c8a466 Mon Sep 17 00:00:00 2001 From: yamaoka Date: Fri, 12 Apr 2002 12:10:17 +0000 Subject: [PATCH] Synch with Oort Gnus. --- lisp/ChangeLog | 25 +++++++++++++++++++++---- lisp/gnus-sum.el | 19 ++++++++++--------- lisp/gnus-uu.el | 11 ++++++----- lisp/nnfolder.el | 5 +++-- lisp/nnimap.el | 4 ++-- lisp/nnmbox.el | 5 +++-- lisp/nnml.el | 8 ++++---- 7 files changed, 49 insertions(+), 28 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5445b16..0b0de31 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,24 @@ -2002-04-12 Daiki Ueno +2002-04-11 Stefan Monnier + + * gnus-sum.el (gnus-update-summary-mark-positions) + (gnus-summary-toggle-header): + * gnus-uu.el (gnus-uu-binhex-article, gnus-uu-reginize-string) + (gnus-uu-expand-numbers, gnus-uu-post-make-mime) + (gnus-uu-post-encoded): + * nnfolder.el (nnfolder-possibly-change-group): + * nnimap.el (nnimap-retrieve-headers): + * nnmbox.el (nnmbox-create-mbox): Don't assume point-min == 1. + +2002-04-08 Stefan Monnier + + * nnml.el (nnml-save-nov, nnml-generate-nov-file): + * pop3.el (pop3-md5): Don't hardcode point-min == 1. + +2002-04-12 Katsumi Yamaoka * gnus-srvr.el (gnus-server-set-info): Clear `gnus-server-method-cache' when `gnus-server-alist' is changed. + From Daiki Ueno . 2002-04-11 Simon Josefsson @@ -1195,8 +1212,8 @@ 2002-01-25 Simon Josefsson - * pop3.el (pop3-munge-message-separator): Work if no date. From - Marius Vollmer . + * pop3.el (pop3-munge-message-separator): Work if no date. + Trivial patch from Marius Vollmer . 2002-01-25 Lars Magne Ingebrigtsen @@ -3090,7 +3107,7 @@ 2001-12-03 11:00:00 ShengHuo ZHU * pop3.el (pop3-munge-message-separator): Only use valid date. - From Michael Welsh Duggan . + Trivial patch from Michael Welsh Duggan . * Makefile.in: gnus-load.elc may not be generated. diff --git a/lisp/gnus-sum.el b/lisp/gnus-sum.el index b5a6ae7..5895bd2 100644 --- a/lisp/gnus-sum.el +++ b/lisp/gnus-sum.el @@ -3039,17 +3039,19 @@ buffer that was in action when the last article was fetched." 0 nil 128 t nil "" nil 1) (goto-char (point-min)) (setq pos (list (cons 'unread (and (search-forward "\200" nil t) - (- (point) 2))))) + (- (point) (point-min) 1))))) (goto-char (point-min)) (push (cons 'replied (and (search-forward "\201" nil t) - (- (point) 2))) + (- (point) (point-min) 1))) pos) (goto-char (point-min)) - (push (cons 'score (and (search-forward "\202" nil t) (- (point) 2))) + (push (cons 'score (and (search-forward "\202" nil t) + (- (point) (point-min) 1))) pos) (goto-char (point-min)) (push (cons 'download - (and (search-forward "\203" nil t) (- (point) 2))) + (and (search-forward "\203" nil t) + (- (point) (point-min) 1))) pos))) (setq gnus-summary-mark-positions pos)))) @@ -8400,7 +8402,7 @@ If ARG is a negative number, hide the unwanted header lines." (save-restriction (let* ((buffer-read-only nil) (inhibit-point-motion-hooks t) - hidden e) + hidden s e) (save-restriction (article-narrow-to-head) (setq e (point-max) @@ -8409,12 +8411,11 @@ If ARG is a negative number, hide the unwanted header lines." (gnus-article-hidden-text-p 'headers)))) (delete-region (point-min) e) (goto-char (point-min)) - (save-excursion - (set-buffer gnus-original-article-buffer) - (goto-char (point-min)) + (with-current-buffer gnus-original-article-buffer + (goto-char (setq s (point-min))) (setq e (search-forward "\n\n" nil t) e (if e (1- e) (point-max)))) - (insert-buffer-substring gnus-original-article-buffer 1 e) + (insert-buffer-substring gnus-original-article-buffer s e) (save-restriction (narrow-to-region (point-min) (point)) (article-decode-encoded-words) diff --git a/lisp/gnus-uu.el b/lisp/gnus-uu.el index 1c52075..8f8c2dc 100644 --- a/lisp/gnus-uu.el +++ b/lisp/gnus-uu.el @@ -951,7 +951,8 @@ When called interactively, prompt for REGEXP." (if (looking-at gnus-uu-binhex-begin-line) (progn (setq state (list 'begin)) - (write-region 1 1 gnus-uu-binhex-article-name)) + (write-region (point-min) (point-min) + gnus-uu-binhex-article-name)) (setq state (list 'middle))) (goto-char (point-max)) (re-search-backward (concat gnus-uu-binhex-body-line "\\|" @@ -1064,7 +1065,7 @@ When called interactively, prompt for REGEXP." (while (re-search-forward "[ \t]+" nil t) (replace-match "[ \t]+" t t)) - (buffer-substring 1 (point-max)))) + (buffer-substring (point-min) (point-max)))) (defun gnus-uu-get-list-of-articles (n) ;; If N is non-nil, the article numbers of the N next articles @@ -1914,7 +1915,7 @@ The user will be asked for a file name." (goto-char (point-min)) (re-search-forward (concat "^" (regexp-quote mail-header-separator) "$")) (forward-line -1) - (narrow-to-region 1 (point)) + (narrow-to-region (point-min) (point)) (unless (mail-fetch-field "mime-version") (widen) (insert "MIME-Version: 1.0\n")) @@ -2004,7 +2005,7 @@ If no file has been included, the user will be asked for a file." (erase-buffer) (insert-buffer-substring post-buf beg-binary end-binary) (goto-char (point-min)) - (setq length (count-lines 1 (point-max))) + (setq length (count-lines (point-min) (point-max))) (setq parts (/ length gnus-uu-post-length)) (unless (< (% length gnus-uu-post-length) 4) (incf parts))) @@ -2017,7 +2018,7 @@ If no file has been included, the user will be asked for a file." (re-search-forward (concat "^" (regexp-quote mail-header-separator) "$") nil t) (beginning-of-line) - (setq header (buffer-substring 1 (point))) + (setq header (buffer-substring (point-min) (point))) (goto-char (point-min)) (when gnus-uu-post-separate-description diff --git a/lisp/nnfolder.el b/lisp/nnfolder.el index 617335c..6c3bfd0 100644 --- a/lisp/nnfolder.el +++ b/lisp/nnfolder.el @@ -1,5 +1,5 @@ ;;; nnfolder.el --- mail folder access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Simon Josefsson (adding MARKS) @@ -714,7 +714,8 @@ deleted. Point is left where the deleted region was." (let ((nnmail-file-coding-system (or nnfolder-file-coding-system-for-write nnfolder-file-coding-system-for-write))) - (nnmail-write-region 1 1 file t 'nomesg))) + (nnmail-write-region (point-min) (point-min) + file t 'nomesg))) (when (setq nnfolder-current-buffer (nnfolder-read-folder group)) (set-buffer nnfolder-current-buffer) (push (list group nnfolder-current-buffer) diff --git a/lisp/nnimap.el b/lisp/nnimap.el index be9f8cc..a556bc5 100644 --- a/lisp/nnimap.el +++ b/lisp/nnimap.el @@ -671,8 +671,8 @@ If EXAMINE is non-nil the group is selected read-only." (cons low high) group server)) (when (buffer-modified-p) (nnmail-write-region - 1 (point-max) (nnimap-group-overview-filename group server) - nil 'nomesg)) + (point-min) (point-max) + (nnimap-group-overview-filename group server) nil 'nomesg)) (nnheader-nov-delete-outside-range low high)))) 'nov))) diff --git a/lisp/nnmbox.el b/lisp/nnmbox.el index ced6c4f..8157bec 100644 --- a/lisp/nnmbox.el +++ b/lisp/nnmbox.el @@ -1,6 +1,6 @@ ;;; nnmbox.el --- mail mbox access for Gnus -;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000 +;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 ;; Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen @@ -611,7 +611,8 @@ nnmbox-file-coding-system)) (dir (file-name-directory nnmbox-mbox-file))) (and dir (gnus-make-directory dir)) - (nnmail-write-region 1 1 nnmbox-mbox-file t 'nomesg)))) + (nnmail-write-region (point-min) (point-min) + nnmbox-mbox-file t 'nomesg)))) (defun nnmbox-read-mbox () (nnmail-activate 'nnmbox) diff --git a/lisp/nnml.el b/lisp/nnml.el index bc6a77e..d27213f 100644 --- a/lisp/nnml.el +++ b/lisp/nnml.el @@ -747,8 +747,8 @@ marks file will be regenerated properly by Gnus.") (when (buffer-name (cdar nnml-nov-buffer-alist)) (set-buffer (cdar nnml-nov-buffer-alist)) (when (buffer-modified-p) - (nnmail-write-region 1 (point-max) nnml-nov-buffer-file-name - nil 'nomesg)) + (nnmail-write-region (point-min) (point-max) + nnml-nov-buffer-file-name nil 'nomesg)) (set-buffer-modified-p nil) (kill-buffer (current-buffer))) (setq nnml-nov-buffer-alist (cdr nnml-nov-buffer-alist))))) @@ -837,7 +837,7 @@ marks file will be regenerated properly by Gnus.") (progn (re-search-forward "\n\r?\n" nil t) (setq chars (- (point-max) (point))) - (max 1 (1- (point))))) + (max (point-min) (1- (point))))) (unless (zerop (buffer-size)) (goto-char (point-min)) (setq headers (nnml-parse-head chars (caar files))) @@ -849,7 +849,7 @@ marks file will be regenerated properly by Gnus.") (setq files (cdr files))) (save-excursion (set-buffer nov-buffer) - (nnmail-write-region 1 (point-max) nov nil 'nomesg) + (nnmail-write-region (point-min) (point-max) nov nil 'nomesg) (kill-buffer (current-buffer)))))) (defun nnml-nov-delete-article (group article) -- 1.7.10.4