diff options
author | Glenn Morris <rgm@gnu.org> | 2016-03-17 00:14:11 -0700 |
---|---|---|
committer | Glenn Morris <rgm@gnu.org> | 2016-03-17 00:14:11 -0700 |
commit | 58862751bde2611d9ea99a33ecb5b0c13a7513b9 (patch) | |
tree | e04c2907816b29932fb83ecf327f26b219a09bec /lisp/gnus/mml2015.el | |
parent | 327c31b33cb175623aa788613c031a5acc4c856f (diff) | |
download | emacs-58862751bde2611d9ea99a33ecb5b0c13a7513b9.tar.gz |
Simplify some rococo Gnus code that loads or tests for other libraries.
* lisp/gnus/gnus-art.el (gnus-treat-ansi-sequences): Simplify default.
* lisp/gnus/mml-smime.el (epg): Simply require it.
(mml-smime-use): Simplify the default. Doc fix.
* lisp/gnus/mml2015.el (epg-config): Require it.
(mml2015-use): Simplify the default.
* lisp/gnus/smime.el (password-cache): Simply require it.
(password-read-and-add): Remove declaration.
Diffstat (limited to 'lisp/gnus/mml2015.el')
-rw-r--r-- | lisp/gnus/mml2015.el | 23 |
1 files changed, 2 insertions, 21 deletions
diff --git a/lisp/gnus/mml2015.el b/lisp/gnus/mml2015.el index 309f1a77ff0..0d64849673e 100644 --- a/lisp/gnus/mml2015.el +++ b/lisp/gnus/mml2015.el @@ -37,6 +37,7 @@ (require 'mm-util) (require 'mml) (require 'mml-sec) +(require 'epg-config) (defvar mc-pgp-always-sign) @@ -47,27 +48,7 @@ ;; Maybe this should be in eg mml-sec.el (and have a different name). ;; Then mml1991 would not need to require mml2015, and mml1991-use ;; could be removed. -(defvar mml2015-use (or - (progn - (ignore-errors (require 'epg-config)) - (and (fboundp 'epg-check-configuration) - 'epg)) - (progn - (let ((abs-file (locate-library "pgg"))) - ;; Don't load PGG if it is marked as obsolete - ;; (Emacs 24). - (when (and abs-file - (not (string-match "/obsolete/[^/]*\\'" - abs-file))) - (ignore-errors (require 'pgg)) - (and (fboundp 'pgg-sign-region) - 'pgg)))) - (progn (ignore-errors - (load "mc-toplev")) - (and (fboundp 'mc-encrypt-generic) - (fboundp 'mc-sign-generic) - (fboundp 'mc-cleanup-recipient-headers) - 'mailcrypt))) +(defvar mml2015-use 'epg "The package used for PGP/MIME. Valid packages include `epg', `pgg' and `mailcrypt'.") |