[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#30669: Suppress "No MH variant found" messages

From: Glenn Morris
Subject: bug#30669: Suppress "No MH variant found" messages
Date: Fri, 02 Mar 2018 21:38:54 -0500
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

Minor revision:

diff --git i/lisp/mh-e/mh-comp.el w/lisp/mh-e/mh-comp.el
index cfdd2ae..9415293 100644
--- i/lisp/mh-e/mh-comp.el
+++ w/lisp/mh-e/mh-comp.el
@@ -1056,6 +1056,7 @@ mh-compose-and-send-mail
 (defun mh-insert-x-mailer ()
   "Append an X-Mailer field to the header.
 The versions of MH-E, Emacs, and MH are shown."
+  (or mh-variant-in-use (mh-variant-set mh-variant))
   ;; Lazily initialize mh-x-mailer-string.
   (when (and mh-insert-x-mailer-flag (null mh-x-mailer-string))
     (setq mh-x-mailer-string
diff --git i/lisp/mh-e/mh-e.el w/lisp/mh-e/mh-e.el
index 05ff672..7b587a8 100644
--- i/lisp/mh-e/mh-e.el
+++ w/lisp/mh-e/mh-e.el
@@ -410,6 +410,8 @@ mh-run-time-gnus-version
   (require 'gnus)
+(defvar mh-variant)
 (defun mh-version ()
   "Display version information about MH-E and the MH mail handling system."
@@ -430,6 +432,7 @@ mh-version
   ;; Emacs version.
   (insert (emacs-version) "\n\n")
   ;; MH version.
+  (or mh-variant-in-use (mh-variant-set mh-variant))
   (if mh-variant-in-use
       (insert mh-variant-in-use "\n"
               " mh-progs:\t" mh-progs "\n"
@@ -876,6 +879,7 @@ mh-variant-set-variant
 (defun mh-variant-p (&rest variants)
   "Return t if variant is any of VARIANTS.
 Currently known variants are `MH', `nmh', and `gnu-mh'."
+  (or mh-variant-in-use (mh-variant-set mh-variant))
   (let ((variant-in-use
          (cadr (assoc 'variant (assoc mh-variant-in-use (mh-variants))))))
     (not (null (member variant-in-use variants)))))
@@ -972,6 +976,7 @@ mh-variant
   :set (lambda (symbol value)
          (set-default symbol value)     ;Done in mh-variant-set-variant!
          (mh-variant-set value))
+  :initialize 'custom-initialize-default
   :group 'mh-e
   :package-version '(MH-E . "8.0"))

reply via email to

[Prev in Thread] Current Thread [Next in Thread]