diff options
| author | Gnus developers | 2011-01-02 11:23:02 +0000 |
|---|---|---|
| committer | Katsumi Yamaoka | 2011-01-02 11:23:02 +0000 |
| commit | bb7f5cbcda931661c8dc3311603ac764fa87a639 (patch) | |
| tree | 311c07278ad7497e54b3f7cafb50fbf6185b026f | |
| parent | 7927f48d454f33668f9dcef6b2d9476d24fe54bb (diff) | |
| download | emacs-bb7f5cbcda931661c8dc3311603ac764fa87a639.tar.gz emacs-bb7f5cbcda931661c8dc3311603ac764fa87a639.zip | |
Merge changes made in Gnus trunk.
mm-view.el (mml-smime): Require.
mm-view.el (mm-view-pkcs7-decrypt): If mml-smime-use is set to 'epg, use EPG to decrypt S/MIME messages instead of openssl.
nnimap.el (nnimap-request-group): Avoid double SELECT on `M-g'.
gnus-group.el (gnus-group-kill-group): Don't try to update the group status is the group clearly is unreachable.
auth-source.el (auth-source-create): Add the optional second parameter to `local-variable-p' to be compatible with XEmacs.
nnml.el (nnml-request-article): Allow requesting by Message-ID to work when using a compressed nnml folder.
gnus-sum.el (gnus-select-newsgroup): Don't propagate marks to backends after sanitising on entry, because this never makes sense: If the articles have gone missing, then the data no longer exists on the backend, and if they haven't, then Gnus is wrong, and shouldn't overwrite anything anyway.
shr.el (shr-insert-document): Bind shr-width dynamically to window-width if it's nil.
shr.el (shr-width, shr-insert-document): Allow nil as shr-width value with the meaning of using the full emacs window width for rendering.
| -rw-r--r-- | lisp/gnus/ChangeLog | 40 | ||||
| -rw-r--r-- | lisp/gnus/auth-source.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/gnus-group.el | 9 | ||||
| -rw-r--r-- | lisp/gnus/gnus-sum.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/mm-view.el | 31 | ||||
| -rw-r--r-- | lisp/gnus/nnimap.el | 4 | ||||
| -rw-r--r-- | lisp/gnus/nnml.el | 9 | ||||
| -rw-r--r-- | lisp/gnus/shr.el | 13 |
8 files changed, 87 insertions, 27 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 63cc0ba141f..465ff2b3cab 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,43 @@ | |||
| 1 | 2011-01-02 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 2 | |||
| 3 | * mm-view.el (mml-smime): Require. | ||
| 4 | |||
| 5 | 2010-12-20 David Engster <deng@eml.cc> | ||
| 6 | |||
| 7 | * mm-view.el (mm-view-pkcs7-decrypt): If mml-smime-use is set to 'epg, | ||
| 8 | use EPG to decrypt S/MIME messages instead of openssl. | ||
| 9 | |||
| 10 | 2011-01-02 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 11 | |||
| 12 | * nnimap.el (nnimap-request-group): Avoid double SELECT on `M-g'. | ||
| 13 | |||
| 14 | * gnus-group.el (gnus-group-kill-group): Don't try to update the group | ||
| 15 | status is the group clearly is unreachable. | ||
| 16 | |||
| 17 | * auth-source.el (auth-source-create): Add the optional second | ||
| 18 | parameter to `local-variable-p' to be compatible with XEmacs. | ||
| 19 | |||
| 20 | 2011-01-02 Wang Diancheng <dcwang@kingbase.com.cn> (tiny change) | ||
| 21 | |||
| 22 | * nnml.el (nnml-request-article): Allow requesting by Message-ID to | ||
| 23 | work when using a compressed nnml folder. | ||
| 24 | |||
| 25 | 2011-01-02 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 26 | |||
| 27 | * gnus-sum.el (gnus-select-newsgroup): Don't propagate marks to | ||
| 28 | backends after sanitising on entry, because this never makes sense: | ||
| 29 | If the articles have gone missing, then the data no longer exists on | ||
| 30 | the backend, and if they haven't, then Gnus is wrong, and shouldn't | ||
| 31 | overwrite anything anyway. | ||
| 32 | |||
| 33 | * shr.el (shr-insert-document): Bind shr-width dynamically to | ||
| 34 | window-width if it's nil. | ||
| 35 | |||
| 36 | 2010-12-30 Tassilo Horn <tassilo@member.fsf.org> | ||
| 37 | |||
| 38 | * shr.el (shr-width, shr-insert-document): Allow nil as shr-width value | ||
| 39 | with the meaning of using the full emacs window width for rendering. | ||
| 40 | |||
| 1 | 2010-12-27 Daiki Ueno <ueno@unixuser.org> | 41 | 2010-12-27 Daiki Ueno <ueno@unixuser.org> |
| 2 | 42 | ||
| 3 | * mml2015.el (mml2015-epg-sign, mml2015-epg-encrypt): Take care the | 43 | * mml2015.el (mml2015-epg-sign, mml2015-epg-encrypt): Take care the |
diff --git a/lisp/gnus/auth-source.el b/lisp/gnus/auth-source.el index 5d386302903..70d9323cb79 100644 --- a/lisp/gnus/auth-source.el +++ b/lisp/gnus/auth-source.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; auth-source.el --- authentication sources for Gnus and Emacs | 1 | ;;; auth-source.el --- authentication sources for Gnus and Emacs |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2008, 2009, 2010 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Ted Zlatanov <tzz@lifelogs.com> | 5 | ;; Author: Ted Zlatanov <tzz@lifelogs.com> |
| 6 | ;; Keywords: news | 6 | ;; Keywords: news |
| @@ -370,7 +370,7 @@ Return structure as specified by MODE." | |||
| 370 | ;; making `epa-file-encrypt-to' local to this buffer lets | 370 | ;; making `epa-file-encrypt-to' local to this buffer lets |
| 371 | ;; epa-file skip the key selection query (see the | 371 | ;; epa-file skip the key selection query (see the |
| 372 | ;; `local-variable-p' check in `epa-file-write-region'). | 372 | ;; `local-variable-p' check in `epa-file-write-region'). |
| 373 | (unless (local-variable-p 'epa-file-encrypt-to) | 373 | (unless (local-variable-p 'epa-file-encrypt-to (current-buffer)) |
| 374 | (make-local-variable 'epa-file-encrypt-to)) | 374 | (make-local-variable 'epa-file-encrypt-to)) |
| 375 | (if (listp auth-source-gpg-encrypt-to) | 375 | (if (listp auth-source-gpg-encrypt-to) |
| 376 | (setq epa-file-encrypt-to auth-source-gpg-encrypt-to))) | 376 | (setq epa-file-encrypt-to auth-source-gpg-encrypt-to))) |
diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 9ce4f86f3ab..2044d5714bd 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el | |||
| @@ -1,7 +1,8 @@ | |||
| 1 | ;;; gnus-group.el --- group mode commands for Gnus | 1 | ;;; gnus-group.el --- group mode commands for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 4 | ;; 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software |
| 5 | ;; Foundation, Inc. | ||
| 5 | 6 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 7 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 7 | ;; Keywords: news | 8 | ;; Keywords: news |
| @@ -3790,7 +3791,8 @@ of groups killed." | |||
| 3790 | gnus-list-of-killed-groups)) | 3791 | gnus-list-of-killed-groups)) |
| 3791 | (gnus-group-change-level | 3792 | (gnus-group-change-level |
| 3792 | (if entry entry group) gnus-level-killed (if entry nil level)) | 3793 | (if entry entry group) gnus-level-killed (if entry nil level)) |
| 3793 | (gnus-request-update-group-status group 'unsubscribe) | 3794 | (when (numberp (gnus-group-unread group)) |
| 3795 | (gnus-request-update-group-status group 'unsubscribe)) | ||
| 3794 | (message "Killed group %s" (gnus-group-decoded-name group))) | 3796 | (message "Killed group %s" (gnus-group-decoded-name group))) |
| 3795 | ;; If there are lots and lots of groups to be killed, we use | 3797 | ;; If there are lots and lots of groups to be killed, we use |
| 3796 | ;; this thing instead. | 3798 | ;; this thing instead. |
| @@ -3814,7 +3816,8 @@ of groups killed." | |||
| 3814 | ;; There may be more than one instance displayed. | 3816 | ;; There may be more than one instance displayed. |
| 3815 | (while (gnus-group-goto-group group) | 3817 | (while (gnus-group-goto-group group) |
| 3816 | (gnus-delete-line)) | 3818 | (gnus-delete-line)) |
| 3817 | (gnus-request-update-group-status group 'unsubscribe)) | 3819 | (when (numberp (gnus-group-unread group)) |
| 3820 | (gnus-request-update-group-status group 'unsubscribe))) | ||
| 3818 | (gnus-make-hashtable-from-newsrc-alist)) | 3821 | (gnus-make-hashtable-from-newsrc-alist)) |
| 3819 | 3822 | ||
| 3820 | (gnus-group-position-point) | 3823 | (gnus-group-position-point) |
diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index 1966e4af6c9..9a21a9c7f68 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; gnus-sum.el --- summary mode commands for Gnus | 1 | ;;; gnus-sum.el --- summary mode commands for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, | 3 | ;; Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
| 4 | ;; 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 4 | ;; 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 7 | ;; Keywords: news | 7 | ;; Keywords: news |
| @@ -5603,7 +5603,7 @@ If SELECT-ARTICLES, only select those articles from GROUP." | |||
| 5603 | 5603 | ||
| 5604 | (setq gnus-newsgroup-processable nil) | 5604 | (setq gnus-newsgroup-processable nil) |
| 5605 | 5605 | ||
| 5606 | (gnus-update-read-articles group gnus-newsgroup-unreads) | 5606 | (gnus-update-read-articles group gnus-newsgroup-unreads t) |
| 5607 | 5607 | ||
| 5608 | ;; Adjust and set lists of article marks. | 5608 | ;; Adjust and set lists of article marks. |
| 5609 | (when info | 5609 | (when info |
diff --git a/lisp/gnus/mm-view.el b/lisp/gnus/mm-view.el index 083781b0f9d..61d5b32b2c7 100644 --- a/lisp/gnus/mm-view.el +++ b/lisp/gnus/mm-view.el | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | ;;; mm-view.el --- functions for viewing MIME objects | 1 | ;;; mm-view.el --- functions for viewing MIME objects |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, | 3 | ;; Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, |
| 4 | ;; 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 4 | ;; 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc. |
| 5 | 5 | ||
| 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 6 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 7 | ;; This file is part of GNU Emacs. | 7 | ;; This file is part of GNU Emacs. |
| @@ -32,6 +32,7 @@ | |||
| 32 | (require 'mm-bodies) | 32 | (require 'mm-bodies) |
| 33 | (require 'mm-decode) | 33 | (require 'mm-decode) |
| 34 | (require 'smime) | 34 | (require 'smime) |
| 35 | (require 'mml-smime) | ||
| 35 | 36 | ||
| 36 | (autoload 'gnus-completing-read "gnus-util") | 37 | (autoload 'gnus-completing-read "gnus-util") |
| 37 | (autoload 'gnus-window-inside-pixel-edges "gnus-ems") | 38 | (autoload 'gnus-window-inside-pixel-edges "gnus-ems") |
| @@ -683,17 +684,23 @@ | |||
| 683 | (defun mm-view-pkcs7-decrypt (handle &optional from) | 684 | (defun mm-view-pkcs7-decrypt (handle &optional from) |
| 684 | (insert-buffer-substring (mm-handle-buffer handle)) | 685 | (insert-buffer-substring (mm-handle-buffer handle)) |
| 685 | (goto-char (point-min)) | 686 | (goto-char (point-min)) |
| 686 | (insert "MIME-Version: 1.0\n") | 687 | (if (eq mml-smime-use 'epg) |
| 687 | (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m") | 688 | ;; Use EPG/gpgsm |
| 688 | (smime-decrypt-region | 689 | (let ((part (base64-decode-string (buffer-string)))) |
| 689 | (point-min) (point-max) | 690 | (erase-buffer) |
| 690 | (if (= (length smime-keys) 1) | 691 | (insert (epg-decrypt-string (epg-make-context 'CMS) part))) |
| 691 | (cadar smime-keys) | 692 | ;; Use openssl |
| 692 | (smime-get-key-by-email | 693 | (insert "MIME-Version: 1.0\n") |
| 693 | (gnus-completing-read | 694 | (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m") |
| 694 | "Decipher using key" | 695 | (smime-decrypt-region |
| 695 | smime-keys nil nil nil (car-safe (car-safe smime-keys))))) | 696 | (point-min) (point-max) |
| 696 | from) | 697 | (if (= (length smime-keys) 1) |
| 698 | (cadar smime-keys) | ||
| 699 | (smime-get-key-by-email | ||
| 700 | (gnus-completing-read | ||
| 701 | "Decipher using key" | ||
| 702 | smime-keys nil nil nil (car-safe (car-safe smime-keys))))) | ||
| 703 | from)) | ||
| 697 | (goto-char (point-min)) | 704 | (goto-char (point-min)) |
| 698 | (while (search-forward "\r\n" nil t) | 705 | (while (search-forward "\r\n" nil t) |
| 699 | (replace-match "\n")) | 706 | (replace-match "\n")) |
diff --git a/lisp/gnus/nnimap.el b/lisp/gnus/nnimap.el index acbb091b356..1899b0ef030 100644 --- a/lisp/gnus/nnimap.el +++ b/lisp/gnus/nnimap.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; nnimap.el --- IMAP interface for Gnus | 1 | ;;; nnimap.el --- IMAP interface for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2010 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2010, 2011 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 6 | ;; Simon Josefsson <simon@josefsson.org> | 6 | ;; Simon Josefsson <simon@josefsson.org> |
| @@ -639,7 +639,7 @@ textual parts.") | |||
| 639 | (let ((result (nnimap-possibly-change-group | 639 | (let ((result (nnimap-possibly-change-group |
| 640 | ;; Don't SELECT the group if we're going to select it | 640 | ;; Don't SELECT the group if we're going to select it |
| 641 | ;; later, anyway. | 641 | ;; later, anyway. |
| 642 | (if (and dont-check | 642 | (if (and (not dont-check) |
| 643 | (assoc group nnimap-current-infos)) | 643 | (assoc group nnimap-current-infos)) |
| 644 | nil | 644 | nil |
| 645 | group) | 645 | group) |
diff --git a/lisp/gnus/nnml.el b/lisp/gnus/nnml.el index 46a6d903f7e..ba64ae8b092 100644 --- a/lisp/gnus/nnml.el +++ b/lisp/gnus/nnml.el | |||
| @@ -1,7 +1,8 @@ | |||
| 1 | ;;; nnml.el --- mail spool access for Gnus | 1 | ;;; nnml.el --- mail spool access for Gnus |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, | 3 | ;; Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, |
| 4 | ;; 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. | 4 | ;; 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software |
| 5 | ;; Foundation, Inc. | ||
| 5 | 6 | ||
| 6 | ;; Authors: Didier Verna <didier@xemacs.org> (adding compaction) | 7 | ;; Authors: Didier Verna <didier@xemacs.org> (adding compaction) |
| 7 | ;; Simon Josefsson <simon@josefsson.org> (adding MARKS) | 8 | ;; Simon Josefsson <simon@josefsson.org> (adding MARKS) |
| @@ -235,7 +236,11 @@ non-nil.") | |||
| 235 | (nnheader-article-to-file-alist | 236 | (nnheader-article-to-file-alist |
| 236 | (setq gpath (nnml-group-pathname (car group-num) | 237 | (setq gpath (nnml-group-pathname (car group-num) |
| 237 | nil server)))))) | 238 | nil server)))))) |
| 238 | (setq path (concat gpath (int-to-string (cdr group-num))))) | 239 | (nnml-update-file-alist) |
| 240 | (setq path (concat gpath (if nnml-use-compressed-files | ||
| 241 | (cdr (assq (cdr group-num) | ||
| 242 | nnml-article-file-alist)) | ||
| 243 | (number-to-string (cdr group-num)))))) | ||
| 239 | (setq path (nnml-article-to-file id))) | 244 | (setq path (nnml-article-to-file id))) |
| 240 | (cond | 245 | (cond |
| 241 | ((not path) | 246 | ((not path) |
diff --git a/lisp/gnus/shr.el b/lisp/gnus/shr.el index 1e95ddee8cb..0ed73cd226b 100644 --- a/lisp/gnus/shr.el +++ b/lisp/gnus/shr.el | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | ;;; shr.el --- Simple HTML Renderer | 1 | ;;; shr.el --- Simple HTML Renderer |
| 2 | 2 | ||
| 3 | ;; Copyright (C) 2010 Free Software Foundation, Inc. | 3 | ;; Copyright (C) 2010, 2011 Free Software Foundation, Inc. |
| 4 | 4 | ||
| 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> | 5 | ;; Author: Lars Magne Ingebrigtsen <larsi@gnus.org> |
| 6 | ;; Keywords: html | 6 | ;; Keywords: html |
| @@ -74,8 +74,12 @@ fit these criteria." | |||
| 74 | :type 'character) | 74 | :type 'character) |
| 75 | 75 | ||
| 76 | (defcustom shr-width fill-column | 76 | (defcustom shr-width fill-column |
| 77 | "Frame width to use for rendering." | 77 | "Frame width to use for rendering. |
| 78 | :type 'integer | 78 | May either be an integer specifying a fixed width in characters, |
| 79 | or nil, meaning that the full width of the window should be | ||
| 80 | used." | ||
| 81 | :type '(choice (integer :tag "Fixed width in characters") | ||
| 82 | (const :tag "Use the width of the window" nil)) | ||
| 79 | :group 'shr) | 83 | :group 'shr) |
| 80 | 84 | ||
| 81 | (defvar shr-content-function nil | 85 | (defvar shr-content-function nil |
| @@ -113,7 +117,8 @@ cid: URL as the argument.") | |||
| 113 | (defun shr-insert-document (dom) | 117 | (defun shr-insert-document (dom) |
| 114 | (setq shr-content-cache nil) | 118 | (setq shr-content-cache nil) |
| 115 | (let ((shr-state nil) | 119 | (let ((shr-state nil) |
| 116 | (shr-start nil)) | 120 | (shr-start nil) |
| 121 | (shr-width (or shr-width (window-width)))) | ||
| 117 | (shr-descend (shr-transform-dom dom)))) | 122 | (shr-descend (shr-transform-dom dom)))) |
| 118 | 123 | ||
| 119 | (defun shr-copy-url () | 124 | (defun shr-copy-url () |