unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH] Fix MH-E mail composition with GNU Mailutils
@ 2018-06-30 19:00 Mike Kupfer
  2018-06-30 19:21 ` Eli Zaretskii
  0 siblings, 1 reply; 4+ messages in thread
From: Mike Kupfer @ 2018-06-30 19:00 UTC (permalink / raw)
  To: emacs-devel

Currently, trying to compose a message using MH-E with Mailutils fails:
no composition buffer is created, and the user gets an obscure error
message about deleting a non-empty directory.  This has been broken for
awhile (i.e., it's not a regression in 26.1), but the fix is pretty
simple.  Is this okay for emacs-26?

diff --git a/lisp/mh-e/mh-comp.el b/lisp/mh-e/mh-comp.el
index a9f809cfa1..aa22df8b18 100644
--- a/lisp/mh-e/mh-comp.el
+++ b/lisp/mh-e/mh-comp.el
@@ -925,8 +925,10 @@ mh-bare-components
                      (list "-form" mh-comp-formfile)))
     (setq new (make-temp-file "comp."))
     (rename-file (concat temp-folder "/" "1") new t)
-    (delete-file (concat temp-folder "/" ".mh_sequences"))
-    (delete-directory temp-folder)
+    ;; The temp folder could contain various metadata files.  Rather
+    ;; than trying to enumerate all the known files, just do a
+    ;; recursive delete on the directory.
+    (delete-directory temp-folder t)
     new))
 
 (defun mh-read-draft (use initial-contents delete-contents-file)

thanks,
mike



^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-07-04 16:38 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-30 19:00 [PATCH] Fix MH-E mail composition with GNU Mailutils Mike Kupfer
2018-06-30 19:21 ` Eli Zaretskii
2018-06-30 20:55   ` Mike Kupfer
2018-07-04 16:38     ` Eli Zaretskii

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).