Commit 63f1dc4f authored by Robert Pluim's avatar Robert Pluim Committed by Paul Eggert

Improve movemail default

* lisp/gnus/mail-source.el (mail-source-movemail-program):
Change default to "movemail".
(mail-source-movemail): Pass just mail-source-movemail-program to
call-process instead of fully specifying it relative to
exec-directory.  Ensures that we will find Mailutils movemail if
it is installed.  (Bug#31737)
parent 0b1a2ae8
......@@ -301,9 +301,9 @@ number."
:group 'mail-source
:type 'number)
(defcustom mail-source-movemail-program nil
(defcustom mail-source-movemail-program "movemail"
"If non-nil, name of program for fetching new mail."
:version "22.1"
:version "26.2"
:group 'mail-source
:type '(choice (const nil) string))
......@@ -682,12 +682,16 @@ Deleting old (> %s day(s)) incoming mail file `%s'." diff bfile)
(setq errors (generate-new-buffer " *mail source loss*"))
(let ((default-directory "/"))
(setq result
;; call-process looks in exec-path, which
;; contains exec-directory, so will find
;; Mailutils movemail if it exists, else it will
;; find "our" movemail in exec-directory.
;; Bug#31737
(or mail-source-movemail-program
(expand-file-name "movemail" exec-directory))
nil errors nil from to)))))
(when (file-exists-p to)
(set-file-modes to mail-source-default-file-modes))
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment