From 0980e1f537d48d6e1eb761b4a7a87878efffc12f Mon Sep 17 00:00:00 2001 From: Lars Ingebrigtsen Date: Mon, 24 Aug 2020 20:50:08 +0200 Subject: [PATCH] Fix error when loading a new, non-existent foo.gpg file * lisp/epa-file.el (epa-file-insert-file-contents): Propagate the correct error upwards (bug introduced by fixing bug#3829, and messing up where the `when' form ended). Reported by "Herbert J. Skuhra" . --- lisp/epa-file.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/epa-file.el b/lisp/epa-file.el index 3b0cc84e5f6..bb027b9abfb 100644 --- a/lisp/epa-file.el +++ b/lisp/epa-file.el @@ -175,9 +175,9 @@ encryption is used." (setq-local epa-file-error error) (add-hook 'find-file-not-found-functions 'epa-file--find-file-not-found-function - nil t) - (signal (if exists 'file-error 'file-missing) - (cons "Opening input file" (cdr error)))))))) + nil t))) + (signal (if exists 'file-error 'file-missing) + (cons "Opening input file" (cdr error)))))) (set-buffer buf) ;In case timer/filter changed/killed it (bug#16029)! (setq-local epa-file-encrypt-to (mapcar #'car (epg-context-result-for -- 2.39.2