From 256e4874e9886e34ba7ebdad769a866d3a6fd3b8 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Tue, 14 Nov 1995 03:48:33 +0000 Subject: [PATCH] (compilation-sentinel): Use the local value of compilation-exit-message-function in the process buffer. --- lisp/progmodes/compile.el | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 92149e4ac8d..172a4622791 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -566,11 +566,7 @@ See `compilation-mode'." ;; buffer killed (set-process-buffer proc nil) (let ((obuf (current-buffer)) - omax opoint - (status (if compilation-exit-message-function - (funcall compilation-exit-message-function - proc msg) - (cons msg (process-exit-status proc))))) + omax opoint) ;; save-excursion isn't the right thing if ;; process-buffer is current-buffer (unwind-protect @@ -578,7 +574,11 @@ See `compilation-mode'." ;; Write something in the compilation buffer ;; and hack its mode line. (set-buffer buffer) - (let ((buffer-read-only nil)) + (let ((buffer-read-only nil) + (status (if compilation-exit-message-function + (funcall compilation-exit-message-function + proc msg) + (cons msg (process-exit-status proc))))) (setq omax (point-max) opoint (point)) (goto-char omax) -- 2.11.4.GIT