From: Daiki Ueno Date: Thu, 30 Jun 2011 20:54:35 +0000 (+0900) Subject: Prevent Gnus from loading PGG. X-Git-Tag: emacs-pretest-24.0.90~104^2~152^2~307 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9ccd6e90d61cc3e995b1c37d3e6981fa511f6668;p=emacs.git Prevent Gnus from loading PGG. * mml2015.el (mml2015-use): Don't try to load PGG on Emacs 24, when EPG is not fully working. --- diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 8133964dd41..e66ae09d391 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,8 @@ +2011-06-30 Daiki Ueno + + * mml2015.el (mml2015-use): Don't try to load PGG on Emacs 24, when EPG + is not fully working. + 2011-06-30 Andrew Cohen * gnus-art.el (gnus-request-article-this-buffer): Use existing function diff --git a/lisp/gnus/mml2015.el b/lisp/gnus/mml2015.el index df106bb6de8..d7070effde5 100644 --- a/lisp/gnus/mml2015.el +++ b/lisp/gnus/mml2015.el @@ -55,9 +55,15 @@ 'epg) (error)) (progn - (ignore-errors (require 'pgg)) - (and (fboundp 'pgg-sign-region) - 'pgg)) + (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-p "/obsolete/[^/]*\\'" + abs-file))) + (ignore-errors (require 'pgg)) + (and (fboundp 'pgg-sign-region) + 'pgg)))) (progn (ignore-errors (load "mc-toplev")) (and (fboundp 'mc-encrypt-generic)