diff options
Diffstat (limited to 'lisp/gnus')
| -rw-r--r-- | lisp/gnus/ChangeLog | 32 | ||||
| -rw-r--r-- | lisp/gnus/gnus-group.el | 6 | ||||
| -rw-r--r-- | lisp/gnus/gnus-msg.el | 3 | ||||
| -rw-r--r-- | lisp/gnus/gnus-registry.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/gnus-sum.el | 3 | ||||
| -rw-r--r-- | lisp/gnus/gnus.el | 15 | ||||
| -rw-r--r-- | lisp/gnus/imap.el | 6 | ||||
| -rw-r--r-- | lisp/gnus/mml.el | 3 | ||||
| -rw-r--r-- | lisp/gnus/nnimap.el | 8 | ||||
| -rw-r--r-- | lisp/gnus/rfc2047.el | 66 |
10 files changed, 127 insertions, 19 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index bc8b89a2519..3cf7292deac 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,35 @@ | |||
| 1 | 2005-02-19 Katsumi Yamaoka <yamaoka@jpl.org> | ||
| 2 | |||
| 3 | * gnus-msg.el (gnus-copy-article-buffer): Quote decoded words | ||
| 4 | containing special characters. | ||
| 5 | |||
| 6 | * gnus-sum.el (gnus-summary-edit-article): Ditto. | ||
| 7 | |||
| 8 | * mml.el (mime-to-mml): Ditto. | ||
| 9 | |||
| 10 | * rfc2047.el (rfc2047-encode-parameter): Use ietf-drums-tspecials. | ||
| 11 | (rfc2047-quote-decoded-words-containing-tspecials): New variable. | ||
| 12 | (rfc2047-decode-region): Quote decoded words containing special | ||
| 13 | characters when rfc2047-quote-decoded-words-containing-tspecials | ||
| 14 | is non-nil. | ||
| 15 | |||
| 16 | 2005-02-16 Teodor Zlatanov <tzz@lifelogs.com> | ||
| 17 | |||
| 18 | * gnus-registry.el (gnus-registry-delete-group): minor bug fix | ||
| 19 | |||
| 20 | * gnus.el (gnus-install-group-spam-parameters): Doc fix. | ||
| 21 | |||
| 22 | 2005-02-15 Simon Josefsson <jas@extundo.com> | ||
| 23 | |||
| 24 | * nnimap.el (nnimap-debug): Doc fix. | ||
| 25 | |||
| 26 | * imap.el (imap-debug): Doc fix. | ||
| 27 | |||
| 28 | 2005-02-14 Reiner Steib <Reiner.Steib@gmx.de> | ||
| 29 | |||
| 30 | * gnus-group.el (gnus-group-make-doc-group): Mention prefix | ||
| 31 | argument in doc string. Make query for type more clear. | ||
| 32 | |||
| 1 | 2005-02-13 Reiner Steib <Reiner.Steib@gmx.de> | 33 | 2005-02-13 Reiner Steib <Reiner.Steib@gmx.de> |
| 2 | 34 | ||
| 3 | * gnus.el (gnus-group-startup-message): Search for gnus images in | 35 | * gnus.el (gnus-group-startup-message): Search for gnus images in |
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 2d6137c0bb5..5892235deac 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el | |||
| @@ -2502,7 +2502,9 @@ group already exists: | |||
| 2502 | (gnus-group-position-point)) | 2502 | (gnus-group-position-point)) |
| 2503 | 2503 | ||
| 2504 | (defun gnus-group-make-doc-group (file type) | 2504 | (defun gnus-group-make-doc-group (file type) |
| 2505 | "Create a group that uses a single file as the source." | 2505 | "Create a group that uses a single file as the source. |
| 2506 | |||
| 2507 | If called with a prefix argument, ask for the file type." | ||
| 2506 | (interactive | 2508 | (interactive |
| 2507 | (list (read-file-name "File name: ") | 2509 | (list (read-file-name "File name: ") |
| 2508 | (and current-prefix-arg 'ask))) | 2510 | (and current-prefix-arg 'ask))) |
| @@ -2511,7 +2513,7 @@ group already exists: | |||
| 2511 | char found) | 2513 | char found) |
| 2512 | (while (not found) | 2514 | (while (not found) |
| 2513 | (message | 2515 | (message |
| 2514 | "%sFile type (mbox, babyl, digest, forward, mmdf, guess) [mbdfag]: " | 2516 | "%sFile type (mbox, babyl, digest, forward, mmdf, guess) [m, b, d, f, a, g]: " |
| 2515 | err) | 2517 | err) |
| 2516 | (setq found (cond ((= (setq char (read-char)) ?m) 'mbox) | 2518 | (setq found (cond ((= (setq char (read-char)) ?m) 'mbox) |
| 2517 | ((= char ?b) 'babyl) | 2519 | ((= char ?b) 'babyl) |
diff --git a/lisp/gnus/gnus-msg.el b/lisp/gnus/gnus-msg.el index 65b3d78aca3..a71dce313d6 100644 --- a/lisp/gnus/gnus-msg.el +++ b/lisp/gnus/gnus-msg.el | |||
| @@ -876,7 +876,8 @@ header line with the old Message-ID." | |||
| 876 | ;; Decode charsets. | 876 | ;; Decode charsets. |
| 877 | (let ((gnus-article-decode-hook | 877 | (let ((gnus-article-decode-hook |
| 878 | (delq 'article-decode-charset | 878 | (delq 'article-decode-charset |
| 879 | (copy-sequence gnus-article-decode-hook)))) | 879 | (copy-sequence gnus-article-decode-hook))) |
| 880 | (rfc2047-quote-decoded-words-containing-tspecials t)) | ||
| 880 | (run-hooks 'gnus-article-decode-hook))))) | 881 | (run-hooks 'gnus-article-decode-hook))))) |
| 881 | gnus-article-copy))) | 882 | gnus-article-copy))) |
| 882 | 883 | ||
diff --git a/lisp/gnus/gnus-registry.el b/lisp/gnus/gnus-registry.el index 0971fea5485..3b7d6e43b43 100644 --- a/lisp/gnus/gnus-registry.el +++ b/lisp/gnus/gnus-registry.el | |||
| @@ -606,7 +606,9 @@ Returns the first place where the trail finds a group name." | |||
| 606 | (when gnus-registry-trim-articles-without-groups | 606 | (when gnus-registry-trim-articles-without-groups |
| 607 | (unless (gnus-registry-group-count id) | 607 | (unless (gnus-registry-group-count id) |
| 608 | (gnus-registry-delete-id id))) | 608 | (gnus-registry-delete-id id))) |
| 609 | (gnus-registry-store-extra-entry id 'mtime (current-time))))) | 609 | ;; is this ID still in the registry? |
| 610 | (when (gethash id gnus-registry-hashtb) | ||
| 611 | (gnus-registry-store-extra-entry id 'mtime (current-time)))))) | ||
| 610 | 612 | ||
| 611 | (defun gnus-registry-delete-id (id) | 613 | (defun gnus-registry-delete-id (id) |
| 612 | "Delete a message ID from the registry." | 614 | "Delete a message ID from the registry." |
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index 1af9e0ca1a7..b5467aa5921 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el | |||
| @@ -9485,7 +9485,8 @@ groups." | |||
| 9485 | `(lambda () | 9485 | `(lambda () |
| 9486 | (let ((mbl mml-buffer-list)) | 9486 | (let ((mbl mml-buffer-list)) |
| 9487 | (setq mml-buffer-list nil) | 9487 | (setq mml-buffer-list nil) |
| 9488 | (mime-to-mml ,'current-handles) | 9488 | (let ((rfc2047-quote-decoded-words-containing-tspecials t)) |
| 9489 | (mime-to-mml ,'current-handles)) | ||
| 9489 | (let ((mbl1 mml-buffer-list)) | 9490 | (let ((mbl1 mml-buffer-list)) |
| 9490 | (setq mml-buffer-list mbl) | 9491 | (setq mml-buffer-list mbl) |
| 9491 | (set (make-local-variable 'mml-buffer-list) mbl1)) | 9492 | (set (make-local-variable 'mml-buffer-list) mbl1)) |
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el index f5dcd296d2b..fa1da9e82f8 100644 --- a/lisp/gnus/gnus.el +++ b/lisp/gnus/gnus.el | |||
| @@ -1819,11 +1819,12 @@ registry.") | |||
| 1819 | :variable gnus-spam-newsgroup-contents | 1819 | :variable gnus-spam-newsgroup-contents |
| 1820 | :variable-default nil | 1820 | :variable-default nil |
| 1821 | :variable-document | 1821 | :variable-document |
| 1822 | "*Groups in which to automatically mark new articles as spam on | 1822 | "*Group classification (spam, ham, or neither). Only |
| 1823 | summary entry. If non-nil, this should be a list of group name | 1823 | meaningful when spam.el is loaded. If non-nil, this should be a |
| 1824 | regexps that should match all groups in which to do automatic spam | 1824 | list of group name regexps associated with a classification for |
| 1825 | tagging, associated with a classification (spam, ham, or neither). | 1825 | each one. In spam groups, new articles are marked as spam on |
| 1826 | This only makes sense for mail groups." | 1826 | summary entry. There is other behavior associated with ham and |
| 1827 | no classification when spam.el is loaded - see the manual." | ||
| 1827 | :variable-group spam | 1828 | :variable-group spam |
| 1828 | :variable-type '(repeat | 1829 | :variable-type '(repeat |
| 1829 | (list :tag "Group contents spam/ham classification" | 1830 | (list :tag "Group contents spam/ham classification" |
| @@ -1840,7 +1841,9 @@ This only makes sense for mail groups." | |||
| 1840 | (const :tag "Unclassified" nil))) | 1841 | (const :tag "Unclassified" nil))) |
| 1841 | :parameter-document | 1842 | :parameter-document |
| 1842 | "The spam classification (spam, ham, or neither) of this group. | 1843 | "The spam classification (spam, ham, or neither) of this group. |
| 1843 | When a spam group is entered, all unread articles are marked as spam.") | 1844 | When a spam group is entered, all unread articles are marked as |
| 1845 | spam. There is other behavior associated with ham and no | ||
| 1846 | classification when spam.el is loaded - see the manual.") | ||
| 1844 | 1847 | ||
| 1845 | (defvar gnus-group-spam-exit-processor-ifile "ifile" | 1848 | (defvar gnus-group-spam-exit-processor-ifile "ifile" |
| 1846 | "OBSOLETE: The ifile summary exit spam processor.") | 1849 | "OBSOLETE: The ifile summary exit spam processor.") |
diff --git a/lisp/gnus/imap.el b/lisp/gnus/imap.el index aba0e88b92f..c7f9d60339f 100644 --- a/lisp/gnus/imap.el +++ b/lisp/gnus/imap.el | |||
| @@ -250,7 +250,11 @@ variable unless you are comfortable with that." | |||
| 250 | :type 'boolean) | 250 | :type 'boolean) |
| 251 | 251 | ||
| 252 | (defcustom imap-debug nil | 252 | (defcustom imap-debug nil |
| 253 | "If non-nil, random debug spews are placed in *imap-debug* buffer." | 253 | "If non-nil, random debug spews are placed in *imap-debug* buffer. |
| 254 | Note that username, passwords and other privacy sensitive | ||
| 255 | information (such as e-mail) may be stored in the *imap-debug* | ||
| 256 | buffer. It is not written to disk, however. Do not enable this | ||
| 257 | variable unless you are comfortable with that." | ||
| 254 | :group 'imap | 258 | :group 'imap |
| 255 | :type 'boolean) | 259 | :type 'boolean) |
| 256 | 260 | ||
diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index 0e018c68903..37f28337733 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el | |||
| @@ -710,7 +710,8 @@ If HANDLES is non-nil, use it instead reparsing the buffer." | |||
| 710 | ;; First decode the head. | 710 | ;; First decode the head. |
| 711 | (save-restriction | 711 | (save-restriction |
| 712 | (message-narrow-to-head) | 712 | (message-narrow-to-head) |
| 713 | (mail-decode-encoded-word-region (point-min) (point-max))) | 713 | (let ((rfc2047-quote-decoded-words-containing-tspecials t)) |
| 714 | (mail-decode-encoded-word-region (point-min) (point-max)))) | ||
| 714 | (unless handles | 715 | (unless handles |
| 715 | (setq handles (mm-dissect-buffer t))) | 716 | (setq handles (mm-dissect-buffer t))) |
| 716 | (goto-char (point-min)) | 717 | (goto-char (point-min)) |
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el index c3afd6381ca..59b0178de42 100644 --- a/lisp/gnus/nnimap.el +++ b/lisp/gnus/nnimap.el | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | ;;; nnimap.el --- imap backend for Gnus | 1 | ;;; nnimap.el --- imap backend for Gnus |
| 2 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004 | 2 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 |
| 3 | ;; Free Software Foundation, Inc. | 3 | ;; Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Simon Josefsson <jas@pdc.kth.se> | 5 | ;; Author: Simon Josefsson <jas@pdc.kth.se> |
| @@ -409,7 +409,11 @@ If this is 'imap-mailbox-lsub, then use a server-side subscription list to | |||
| 409 | restrict visible folders.") | 409 | restrict visible folders.") |
| 410 | 410 | ||
| 411 | (defcustom nnimap-debug nil | 411 | (defcustom nnimap-debug nil |
| 412 | "If non-nil, random debug spews are placed in *nnimap-debug* buffer." | 412 | "If non-nil, random debug spews are placed in *nnimap-debug* buffer. |
| 413 | Note that username, passwords and other privacy sensitive | ||
| 414 | information (such as e-mail) may be stored in the *nnimap-debug* | ||
| 415 | buffer. It is not written to disk, however. Do not enable this | ||
| 416 | variable unless you are comfortable with that." | ||
| 413 | :group 'nnimap | 417 | :group 'nnimap |
| 414 | :type 'boolean) | 418 | :type 'boolean) |
| 415 | 419 | ||
diff --git a/lisp/gnus/rfc2047.el b/lisp/gnus/rfc2047.el index e6461bf2627..6086f422abd 100644 --- a/lisp/gnus/rfc2047.el +++ b/lisp/gnus/rfc2047.el | |||
| @@ -1,5 +1,7 @@ | |||
| 1 | ;;; rfc2047.el --- functions for encoding and decoding rfc2047 messages | 1 | ;;; rfc2047.el --- functions for encoding and decoding rfc2047 messages |
| 2 | ;; Copyright (C) 1998, 1999, 2000, 2002, 2003 Free Software Foundation, Inc. | 2 | |
| 3 | ;; Copyright (C) 1998, 1999, 2000, 2002, 2003, 2004, 2005 | ||
| 4 | ;; Free Software Foundation, Inc. | ||
| 3 | 5 | ||
| 4 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 5 | ;; MORIOKA Tomohiko <morioka@jaist.ac.jp> | 7 | ;; MORIOKA Tomohiko <morioka@jaist.ac.jp> |
| @@ -50,6 +52,7 @@ Value is what BODY returns." | |||
| 50 | 52 | ||
| 51 | (require 'qp) | 53 | (require 'qp) |
| 52 | (require 'mm-util) | 54 | (require 'mm-util) |
| 55 | (require 'ietf-drums) | ||
| 53 | ;; Fixme: Avoid this (used for mail-parse-charset) mm dependence on gnus. | 56 | ;; Fixme: Avoid this (used for mail-parse-charset) mm dependence on gnus. |
| 54 | (require 'mail-prsvr) | 57 | (require 'mail-prsvr) |
| 55 | (require 'base64) | 58 | (require 'base64) |
| @@ -639,6 +642,9 @@ By default, the region is treated as containing addresses (see | |||
| 639 | "=\\?\\([^][\000-\040()<>@,\;:\\\"/?.=]+\\)\\?\\(B\\|Q\\)\ | 642 | "=\\?\\([^][\000-\040()<>@,\;:\\\"/?.=]+\\)\\?\\(B\\|Q\\)\ |
| 640 | \\?\\([!->@-~ +]*\\)\\?=")) | 643 | \\?\\([!->@-~ +]*\\)\\?=")) |
| 641 | 644 | ||
| 645 | (defvar rfc2047-quote-decoded-words-containing-tspecials nil | ||
| 646 | "If non-nil, quote decoded words containing special characters.") | ||
| 647 | |||
| 642 | ;; Fixme: This should decode in place, not cons intermediate strings. | 648 | ;; Fixme: This should decode in place, not cons intermediate strings. |
| 643 | ;; Also check whether it needs to worry about delimiting fields like | 649 | ;; Also check whether it needs to worry about delimiting fields like |
| 644 | ;; encoding. | 650 | ;; encoding. |
| @@ -673,14 +679,66 @@ By default, the region is treated as containing addresses (see | |||
| 673 | (insert (rfc2047-parse-and-decode | 679 | (insert (rfc2047-parse-and-decode |
| 674 | (prog1 | 680 | (prog1 |
| 675 | (match-string 0) | 681 | (match-string 0) |
| 676 | (delete-region (match-beginning 0) (match-end 0))))) | 682 | (delete-region e (match-end 0))))) |
| 677 | ;; Remove newlines between decoded words, though such things | 683 | (while (looking-at rfc2047-encoded-word-regexp) |
| 678 | ;; essentially must not be there. | 684 | (insert (rfc2047-parse-and-decode |
| 685 | (prog1 | ||
| 686 | (match-string 0) | ||
| 687 | (delete-region (point) (match-end 0)))))) | ||
| 679 | (save-restriction | 688 | (save-restriction |
| 680 | (narrow-to-region e (point)) | 689 | (narrow-to-region e (point)) |
| 681 | (goto-char e) | 690 | (goto-char e) |
| 691 | ;; Remove newlines between decoded words, though such | ||
| 692 | ;; things essentially must not be there. | ||
| 682 | (while (re-search-forward "[\n\r]+" nil t) | 693 | (while (re-search-forward "[\n\r]+" nil t) |
| 683 | (replace-match " ")) | 694 | (replace-match " ")) |
| 695 | ;; Quote decoded words if there are special characters | ||
| 696 | ;; which might violate RFC2822. | ||
| 697 | (when (and rfc2047-quote-decoded-words-containing-tspecials | ||
| 698 | (let ((regexp (car (rassq | ||
| 699 | 'address-mime | ||
| 700 | rfc2047-header-encoding-alist)))) | ||
| 701 | (when regexp | ||
| 702 | (save-restriction | ||
| 703 | (widen) | ||
| 704 | (beginning-of-line) | ||
| 705 | (while (and (memq (char-after) '(? ?\t)) | ||
| 706 | (zerop (forward-line -1)))) | ||
| 707 | (looking-at regexp))))) | ||
| 708 | (let (quoted) | ||
| 709 | (goto-char e) | ||
| 710 | (skip-chars-forward " \t") | ||
| 711 | (setq start (point)) | ||
| 712 | (setq quoted (eq (char-after) ?\")) | ||
| 713 | (goto-char (point-max)) | ||
| 714 | (skip-chars-backward " \t") | ||
| 715 | (if (setq quoted (and quoted | ||
| 716 | (> (point) (1+ start)) | ||
| 717 | (eq (char-before) ?\"))) | ||
| 718 | (progn | ||
| 719 | (backward-char) | ||
| 720 | (setq start (1+ start) | ||
| 721 | end (point-marker))) | ||
| 722 | (setq end (point-marker))) | ||
| 723 | (goto-char start) | ||
| 724 | (while (search-forward "\"" end t) | ||
| 725 | (when (prog2 | ||
| 726 | (backward-char) | ||
| 727 | (zerop (% (skip-chars-backward "\\\\") 2)) | ||
| 728 | (goto-char (match-beginning 0))) | ||
| 729 | (insert "\\")) | ||
| 730 | (forward-char)) | ||
| 731 | (when (and (not quoted) | ||
| 732 | (progn | ||
| 733 | (goto-char start) | ||
| 734 | (re-search-forward | ||
| 735 | (concat "[" ietf-drums-tspecials "]") | ||
| 736 | end t))) | ||
| 737 | (goto-char start) | ||
| 738 | (insert "\"") | ||
| 739 | (goto-char end) | ||
| 740 | (insert "\"")) | ||
| 741 | (set-marker end nil))) | ||
| 684 | (goto-char (point-max))) | 742 | (goto-char (point-max))) |
| 685 | (when (and (mm-multibyte-p) | 743 | (when (and (mm-multibyte-p) |
| 686 | mail-parse-charset | 744 | mail-parse-charset |