From 0afdd8d04101a4540a1f4ccca9afc049ebabcf20 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sat, 5 Apr 1997 21:52:58 +0000 Subject: [PATCH] (sgml-validate): Offer to save the buffer first. --- lisp/textmodes/sgml-mode.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index 3b8af26750b..ef3f822cfb2 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el @@ -712,6 +712,9 @@ and move to the line in the SGML document that caused it." (and name (file-name-nondirectory name)))))))) (setq sgml-saved-validate-command command) + (if (or (not compilation-ask-about-save) + (y-or-n-p (message "Save buffer %s? " (buffer-name)))) + (save-buffer)) (compile-internal command "No more errors")) -- 2.39.2