diff options
| author | Miles Bader | 2004-10-12 02:25:56 +0000 |
|---|---|---|
| committer | Miles Bader | 2004-10-12 02:25:56 +0000 |
| commit | e62e7654ac785834b72bfb8784ff34d203d3190f (patch) | |
| tree | a070f2fe34b219c630343526193543c43ae5f607 | |
| parent | 332e51c15c33e5033344932424f4f7af99607ffd (diff) | |
| download | emacs-e62e7654ac785834b72bfb8784ff34d203d3190f.tar.gz emacs-e62e7654ac785834b72bfb8784ff34d203d3190f.zip | |
Revision: miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-610
Merge from gnus--rel--5.10
Patches applied:
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-45
Update from CVS
| -rw-r--r-- | lisp/gnus/ChangeLog | 23 | ||||
| -rw-r--r-- | lisp/gnus/gnus-sum.el | 3 | ||||
| -rw-r--r-- | lisp/gnus/gnus.el | 1 | ||||
| -rw-r--r-- | lisp/gnus/imap.el | 10 | ||||
| -rw-r--r-- | lisp/gnus/mml.el | 3 | ||||
| -rw-r--r-- | lisp/gnus/nnheader.el | 10 | ||||
| -rw-r--r-- | lisp/gnus/pop3.el | 108 |
7 files changed, 104 insertions, 54 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index f4b77297867..782c2a260a6 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,26 @@ | |||
| 1 | 2004-10-10 Reiner Steib <Reiner.Steib@gmx.de> | ||
| 2 | |||
| 3 | * gnus-sum.el: Mention that multibyte characters don't work as marks. | ||
| 4 | |||
| 5 | * gnus.el (message-y-or-n-p): Autoload. | ||
| 6 | |||
| 7 | * pop3.el (pop3-maildrop, pop3-mailhost, pop3-port) | ||
| 8 | (pop3-password-required, pop3-authentication-scheme) | ||
| 9 | (pop3-leave-mail-on-server): Made customizable. | ||
| 10 | (pop3): New custom group. | ||
| 11 | (pop3-retr): Remove `sleep-for' statements. | ||
| 12 | Suggested by Dave Love <fx@gnu.org>. | ||
| 13 | |||
| 14 | * nnheader.el (nnheader-read-timeout): Explain 1.0 timeout for | ||
| 15 | Windows/DOS. | ||
| 16 | |||
| 17 | * imap.el (imap-parse-flag-list, imap-parse-body-extension) | ||
| 18 | (imap-parse-body): Fix incorrect use of `assert'. Suggested by | ||
| 19 | Dave Love <fx@gnu.org>. | ||
| 20 | |||
| 21 | * mml.el (mml-minibuffer-read-disposition): Require match. | ||
| 22 | Suggested by Dave Love <fx@gnu.org>. | ||
| 23 | |||
| 1 | 2004-10-06 Katsumi Yamaoka <yamaoka@jpl.org> | 24 | 2004-10-06 Katsumi Yamaoka <yamaoka@jpl.org> |
| 2 | 25 | ||
| 3 | * gnus-group.el (gnus-update-group-mark-positions): | 26 | * gnus-group.el (gnus-update-group-mark-positions): |
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index 84de9c4e1ab..6f6f728720b 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el | |||
| @@ -428,6 +428,9 @@ this variable specifies group names." | |||
| 428 | (cons :value ("" "") regexp (repeat string)) | 428 | (cons :value ("" "") regexp (repeat string)) |
| 429 | (sexp :value nil)))) | 429 | (sexp :value nil)))) |
| 430 | 430 | ||
| 431 | ;; FIXME: Although the custom type is `character' for the following variables, | ||
| 432 | ;; using multibyte characters (Latin-1, UTF-8) doesn't work. -- rs | ||
| 433 | |||
| 431 | (defcustom gnus-unread-mark ? ;Whitespace | 434 | (defcustom gnus-unread-mark ? ;Whitespace |
| 432 | "*Mark used for unread articles." | 435 | "*Mark used for unread articles." |
| 433 | :group 'gnus-summary-marks | 436 | :group 'gnus-summary-marks |
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el index 979ee2a7c24..bff1c3bba2f 100644 --- a/lisp/gnus/gnus.el +++ b/lisp/gnus/gnus.el | |||
| @@ -34,6 +34,7 @@ | |||
| 34 | (require 'wid-edit) | 34 | (require 'wid-edit) |
| 35 | (require 'mm-util) | 35 | (require 'mm-util) |
| 36 | (require 'nnheader) | 36 | (require 'nnheader) |
| 37 | (autoload 'message-y-or-n-p "message" nil nil 'macro) | ||
| 37 | 38 | ||
| 38 | (defgroup gnus nil | 39 | (defgroup gnus nil |
| 39 | "The coffee-brewing, all singing, all dancing, kitchen sink newsreader." | 40 | "The coffee-brewing, all singing, all dancing, kitchen sink newsreader." |
diff --git a/lisp/gnus/imap.el b/lisp/gnus/imap.el index 754473fa8ec..326c998c5d9 100644 --- a/lisp/gnus/imap.el +++ b/lisp/gnus/imap.el | |||
| @@ -2421,7 +2421,7 @@ Return nil if no complete line has arrived." | |||
| 2421 | 2421 | ||
| 2422 | (defun imap-parse-flag-list () | 2422 | (defun imap-parse-flag-list () |
| 2423 | (let (flag-list start) | 2423 | (let (flag-list start) |
| 2424 | (assert (eq (char-after) ?\() t "In imap-parse-flag-list") | 2424 | (assert (eq (char-after) ?\() nil "In imap-parse-flag-list") |
| 2425 | (while (and (not (eq (char-after) ?\))) | 2425 | (while (and (not (eq (char-after) ?\))) |
| 2426 | (setq start (progn | 2426 | (setq start (progn |
| 2427 | (imap-forward) | 2427 | (imap-forward) |
| @@ -2430,7 +2430,7 @@ Return nil if no complete line has arrived." | |||
| 2430 | (point))) | 2430 | (point))) |
| 2431 | (> (skip-chars-forward "^ )" (imap-point-at-eol)) 0)) | 2431 | (> (skip-chars-forward "^ )" (imap-point-at-eol)) 0)) |
| 2432 | (push (buffer-substring start (point)) flag-list)) | 2432 | (push (buffer-substring start (point)) flag-list)) |
| 2433 | (assert (eq (char-after) ?\)) t "In imap-parse-flag-list") | 2433 | (assert (eq (char-after) ?\)) nil "In imap-parse-flag-list") |
| 2434 | (imap-forward) | 2434 | (imap-forward) |
| 2435 | (nreverse flag-list))) | 2435 | (nreverse flag-list))) |
| 2436 | 2436 | ||
| @@ -2515,7 +2515,7 @@ Return nil if no complete line has arrived." | |||
| 2515 | (while (eq (char-after) ?\ ) | 2515 | (while (eq (char-after) ?\ ) |
| 2516 | (imap-forward) | 2516 | (imap-forward) |
| 2517 | (push (imap-parse-body-extension) b-e)) | 2517 | (push (imap-parse-body-extension) b-e)) |
| 2518 | (assert (eq (char-after) ?\)) t "In imap-parse-body-extension") | 2518 | (assert (eq (char-after) ?\)) nil "In imap-parse-body-extension") |
| 2519 | (imap-forward) | 2519 | (imap-forward) |
| 2520 | (nreverse b-e)) | 2520 | (nreverse b-e)) |
| 2521 | (or (imap-parse-number) | 2521 | (or (imap-parse-number) |
| @@ -2641,7 +2641,7 @@ Return nil if no complete line has arrived." | |||
| 2641 | (push (and (imap-parse-nil) nil) body)) | 2641 | (push (and (imap-parse-nil) nil) body)) |
| 2642 | (setq body | 2642 | (setq body |
| 2643 | (append (imap-parse-body-ext) body))) ;; body-ext-... | 2643 | (append (imap-parse-body-ext) body))) ;; body-ext-... |
| 2644 | (assert (eq (char-after) ?\)) t "In imap-parse-body") | 2644 | (assert (eq (char-after) ?\)) nil "In imap-parse-body") |
| 2645 | (imap-forward) | 2645 | (imap-forward) |
| 2646 | (nreverse body)) | 2646 | (nreverse body)) |
| 2647 | 2647 | ||
| @@ -2701,7 +2701,7 @@ Return nil if no complete line has arrived." | |||
| 2701 | (push (imap-parse-nstring) body) ;; body-fld-md5 | 2701 | (push (imap-parse-nstring) body) ;; body-fld-md5 |
| 2702 | (setq body (append (imap-parse-body-ext) body))) ;; body-ext-1part.. | 2702 | (setq body (append (imap-parse-body-ext) body))) ;; body-ext-1part.. |
| 2703 | 2703 | ||
| 2704 | (assert (eq (char-after) ?\)) t "In imap-parse-body 2") | 2704 | (assert (eq (char-after) ?\)) nil "In imap-parse-body 2") |
| 2705 | (imap-forward) | 2705 | (imap-forward) |
| 2706 | (nreverse body))))) | 2706 | (nreverse body))))) |
| 2707 | 2707 | ||
diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index c2c5bbf91e3..2deb69fe36c 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el | |||
| @@ -946,8 +946,7 @@ See Info node `(emacs-mime)Composing'. | |||
| 946 | "attachment"))) | 946 | "attachment"))) |
| 947 | (disposition (completing-read "Disposition: " | 947 | (disposition (completing-read "Disposition: " |
| 948 | '(("attachment") ("inline") ("")) | 948 | '(("attachment") ("inline") ("")) |
| 949 | nil | 949 | nil t))) |
| 950 | nil))) | ||
| 951 | (if (not (equal disposition "")) | 950 | (if (not (equal disposition "")) |
| 952 | disposition | 951 | disposition |
| 953 | default))) | 952 | default))) |
diff --git a/lisp/gnus/nnheader.el b/lisp/gnus/nnheader.el index 1b6ec636734..7df5ecae205 100644 --- a/lisp/gnus/nnheader.el +++ b/lisp/gnus/nnheader.el | |||
| @@ -74,7 +74,15 @@ Integer values will in effect be rounded up to the nearest multiple of | |||
| 74 | (defvar nnheader-read-timeout | 74 | (defvar nnheader-read-timeout |
| 75 | (if (string-match "windows-nt\\|os/2\\|emx\\|cygwin" | 75 | (if (string-match "windows-nt\\|os/2\\|emx\\|cygwin" |
| 76 | (symbol-name system-type)) | 76 | (symbol-name system-type)) |
| 77 | 1.0 ; why? | 77 | ;; http://thread.gmane.org/v9655t3pjo.fsf@marauder.physik.uni-ulm.de |
| 78 | ;; | ||
| 79 | ;; IIRC, values lower than 1.0 didn't/don't work on Windows/DOS. | ||
| 80 | ;; | ||
| 81 | ;; There should probably be a runtime test to determine the timing | ||
| 82 | ;; resolution, or a primitive to report it. I don't know off-hand | ||
| 83 | ;; what's possible. Perhaps better, maybe the Windows/DOS primitive | ||
| 84 | ;; could round up non-zero timeouts to a minimum of 1.0? | ||
| 85 | 1.0 | ||
| 78 | 0.1) | 86 | 0.1) |
| 79 | "How long nntp should wait between checking for the end of output. | 87 | "How long nntp should wait between checking for the end of output. |
| 80 | Shorter values mean quicker response, but are more CPU intensive.") | 88 | Shorter values mean quicker response, but are more CPU intensive.") |
diff --git a/lisp/gnus/pop3.el b/lisp/gnus/pop3.el index 567ab24e004..e288f6cace2 100644 --- a/lisp/gnus/pop3.el +++ b/lisp/gnus/pop3.el | |||
| @@ -37,25 +37,56 @@ | |||
| 37 | 37 | ||
| 38 | (require 'mail-utils) | 38 | (require 'mail-utils) |
| 39 | 39 | ||
| 40 | (defvar pop3-maildrop (or (user-login-name) (getenv "LOGNAME") (getenv "USER") nil) | 40 | (defgroup pop3 nil |
| 41 | "*POP3 maildrop.") | 41 | "Post Office Protocol" |
| 42 | (defvar pop3-mailhost (or (getenv "MAILHOST") nil) | 42 | :group 'mail |
| 43 | "*POP3 mailhost.") | 43 | :group 'mail-source) |
| 44 | (defvar pop3-port 110 | 44 | |
| 45 | "*POP3 port.") | 45 | (defcustom pop3-maildrop (or (user-login-name) |
| 46 | 46 | (getenv "LOGNAME") | |
| 47 | (defvar pop3-password-required t | 47 | (getenv "USER")) |
| 48 | "*Non-nil if a password is required when connecting to POP server.") | 48 | "*POP3 maildrop." |
| 49 | :version "21.4" ;; Oort Gnus | ||
| 50 | :type 'string | ||
| 51 | :group 'pop3) | ||
| 52 | |||
| 53 | (defcustom pop3-mailhost (or (getenv "MAILHOST") ;; nil -> mismatch | ||
| 54 | "pop3") | ||
| 55 | "*POP3 mailhost." | ||
| 56 | :version "21.4" ;; Oort Gnus | ||
| 57 | :type 'string | ||
| 58 | :group 'pop3) | ||
| 59 | |||
| 60 | (defcustom pop3-port 110 | ||
| 61 | "*POP3 port." | ||
| 62 | :version "21.4" ;; Oort Gnus | ||
| 63 | :type 'number | ||
| 64 | :group 'pop3) | ||
| 65 | |||
| 66 | (defcustom pop3-password-required t | ||
| 67 | "*Non-nil if a password is required when connecting to POP server." | ||
| 68 | :version "21.4" ;; Oort Gnus | ||
| 69 | :type 'boolean | ||
| 70 | :group 'pop3) | ||
| 71 | |||
| 72 | ;; Should this be customizable? | ||
| 49 | (defvar pop3-password nil | 73 | (defvar pop3-password nil |
| 50 | "*Password to use when connecting to POP server.") | 74 | "*Password to use when connecting to POP server.") |
| 51 | 75 | ||
| 52 | (defvar pop3-authentication-scheme 'pass | 76 | (defcustom pop3-authentication-scheme 'pass |
| 53 | "*POP3 authentication scheme. | 77 | "*POP3 authentication scheme. |
| 54 | Defaults to 'pass, for the standard USER/PASS authentication. Other valid | 78 | Defaults to 'pass, for the standard USER/PASS authentication. Other valid |
| 55 | values are 'apop.") | 79 | values are 'apop." |
| 56 | 80 | :version "21.4" ;; Oort Gnus | |
| 57 | (defvar pop3-leave-mail-on-server nil | 81 | :type '(choice (const :tag "USER/PASS" pass) |
| 58 | "*Non-nil if the mail is to be left on the POP server after fetching.") | 82 | (const :tag "APOP" apop)) |
| 83 | :group 'pop3) | ||
| 84 | |||
| 85 | (defcustom pop3-leave-mail-on-server nil | ||
| 86 | "*Non-nil if the mail is to be left on the POP server after fetching." | ||
| 87 | :version "21.4" ;; Oort Gnus | ||
| 88 | :type 'boolean | ||
| 89 | :group 'pop3) | ||
| 59 | 90 | ||
| 60 | (defvar pop3-timestamp nil | 91 | (defvar pop3-timestamp nil |
| 61 | "Timestamp returned when initially connected to the POP server. | 92 | "Timestamp returned when initially connected to the POP server. |
| @@ -71,8 +102,7 @@ Used for APOP authentication.") | |||
| 71 | (crashbuf (get-buffer-create " *pop3-retr*")) | 102 | (crashbuf (get-buffer-create " *pop3-retr*")) |
| 72 | (n 1) | 103 | (n 1) |
| 73 | message-count | 104 | message-count |
| 74 | (pop3-password pop3-password) | 105 | (pop3-password pop3-password)) |
| 75 | ) | ||
| 76 | ;; for debugging only | 106 | ;; for debugging only |
| 77 | (if pop3-debug (switch-to-buffer (process-buffer process))) | 107 | (if pop3-debug (switch-to-buffer (process-buffer process))) |
| 78 | ;; query for password | 108 | ;; query for password |
| @@ -114,8 +144,7 @@ Used for APOP authentication.") | |||
| 114 | "Return the number of messages in the maildrop." | 144 | "Return the number of messages in the maildrop." |
| 115 | (let* ((process (pop3-open-server pop3-mailhost pop3-port)) | 145 | (let* ((process (pop3-open-server pop3-mailhost pop3-port)) |
| 116 | message-count | 146 | message-count |
| 117 | (pop3-password pop3-password) | 147 | (pop3-password pop3-password)) |
| 118 | ) | ||
| 119 | ;; for debugging only | 148 | ;; for debugging only |
| 120 | (if pop3-debug (switch-to-buffer (process-buffer process))) | 149 | (if pop3-debug (switch-to-buffer (process-buffer process))) |
| 121 | ;; query for password | 150 | ;; query for password |
| @@ -159,15 +188,14 @@ Returns the process associated with the connection." | |||
| 159 | (insert output))) | 188 | (insert output))) |
| 160 | 189 | ||
| 161 | (defun pop3-send-command (process command) | 190 | (defun pop3-send-command (process command) |
| 162 | (set-buffer (process-buffer process)) | 191 | (set-buffer (process-buffer process)) |
| 163 | (goto-char (point-max)) | 192 | (goto-char (point-max)) |
| 164 | ;; (if (= (aref command 0) ?P) | 193 | ;; (if (= (aref command 0) ?P) |
| 165 | ;; (insert "PASS <omitted>\r\n") | 194 | ;; (insert "PASS <omitted>\r\n") |
| 166 | ;; (insert command "\r\n")) | 195 | ;; (insert command "\r\n")) |
| 167 | (setq pop3-read-point (point)) | 196 | (setq pop3-read-point (point)) |
| 168 | (goto-char (point-max)) | 197 | (goto-char (point-max)) |
| 169 | (process-send-string process (concat command "\r\n")) | 198 | (process-send-string process (concat command "\r\n"))) |
| 170 | ) | ||
| 171 | 199 | ||
| 172 | (defun pop3-read-response (process &optional return) | 200 | (defun pop3-read-response (process &optional return) |
| 173 | "Read the response from the server. | 201 | "Read the response from the server. |
| @@ -355,27 +383,15 @@ This function currently does nothing.") | |||
| 355 | (while (not (re-search-forward "^\\.\r\n" nil t)) | 383 | (while (not (re-search-forward "^\\.\r\n" nil t)) |
| 356 | ;; Fixme: Shouldn't depend on nnheader. | 384 | ;; Fixme: Shouldn't depend on nnheader. |
| 357 | (nnheader-accept-process-output process) | 385 | (nnheader-accept-process-output process) |
| 358 | ;; bill@att.com ... to save wear and tear on the heap | ||
| 359 | ;; uncommented because the condensed version below is a problem for | ||
| 360 | ;; some. | ||
| 361 | (if (> (buffer-size) 20000) (sleep-for 1)) | ||
| 362 | (if (> (buffer-size) 50000) (sleep-for 1)) | ||
| 363 | (if (> (buffer-size) 100000) (sleep-for 1)) | ||
| 364 | (if (> (buffer-size) 200000) (sleep-for 1)) | ||
| 365 | (if (> (buffer-size) 500000) (sleep-for 1)) | ||
| 366 | ;; bill@att.com | ||
| 367 | ;; condensed into: | ||
| 368 | ;; (sometimes causes problems for really large messages.) | ||
| 369 | ; (if (> (buffer-size) 20000) (sleep-for (/ (buffer-size) 20000))) | ||
| 370 | (goto-char start)) | 386 | (goto-char start)) |
| 371 | (setq pop3-read-point (point-marker)) | 387 | (setq pop3-read-point (point-marker)) |
| 372 | ;; this code does not seem to work for some POP servers... | 388 | ;; this code does not seem to work for some POP servers... |
| 373 | ;; and I cannot figure out why not. | 389 | ;; and I cannot figure out why not. |
| 374 | ; (goto-char (match-beginning 0)) | 390 | ;; (goto-char (match-beginning 0)) |
| 375 | ; (backward-char 2) | 391 | ;; (backward-char 2) |
| 376 | ; (if (not (looking-at "\r\n")) | 392 | ;; (if (not (looking-at "\r\n")) |
| 377 | ; (insert "\r\n")) | 393 | ;; (insert "\r\n")) |
| 378 | ; (re-search-forward "\\.\r\n") | 394 | ;; (re-search-forward "\\.\r\n") |
| 379 | (goto-char (match-beginning 0)) | 395 | (goto-char (match-beginning 0)) |
| 380 | (setq end (point-marker)) | 396 | (setq end (point-marker)) |
| 381 | (pop3-clean-region start end) | 397 | (pop3-clean-region start end) |