From 7b8a295e799d7b957da2ac68cedb3fef1aa3dfef Mon Sep 17 00:00:00 2001 From: Deepak Goel Date: Sun, 18 Sep 2005 12:39:40 +0000 Subject: [PATCH] message format spec fixes, commit # 8 --- lisp/emulation/viper-ex.el | 4 ++-- lisp/emulation/viper-macs.el | 10 +++++++--- lisp/emulation/ws-mode.el | 2 +- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/lisp/emulation/viper-ex.el b/lisp/emulation/viper-ex.el index 87d2d7f5d5a..5321228fe29 100644 --- a/lisp/emulation/viper-ex.el +++ b/lisp/emulation/viper-ex.el @@ -1590,7 +1590,7 @@ reversed." ;; Ex print working directory (defun ex-pwd () - (message default-directory)) + (message "%s" default-directory)) ;; Ex quit command (defun ex-quit () @@ -2230,7 +2230,7 @@ Type 'mak ' (including the space) to run make with no args." (if (buffer-modified-p) "[Modified]" "[Unchanged]"))) (if (< (+ 1 (length info) (length file)) (window-width (minibuffer-window))) - (message (concat file " " info)) + (message "%s" (concat file " " info)) (save-window-excursion (with-output-to-temp-buffer " *viper-info*" (princ (concat "\n" file "\n\n\t" info "\n\n"))) diff --git a/lisp/emulation/viper-macs.el b/lisp/emulation/viper-macs.el index edc5cba1bbe..9349a950e97 100644 --- a/lisp/emulation/viper-macs.el +++ b/lisp/emulation/viper-macs.el @@ -186,7 +186,7 @@ a key is a symbol, e.g., `a', `\\1', `f2', etc., or a list, e.g., variant (if (> (length key-seq) 0) (prin1-to-string (viper-display-macro key-seq)) ""))) - (message message) + (message "%s" message) (setq event (viper-read-key)) ;;(setq event (viper-read-event)) (setq key @@ -263,7 +263,7 @@ a key is a symbol, e.g., `a', `\\1', `f2', etc., or a list, e.g., (prin1-to-string (viper-display-macro key-seq)) ""))) - (message message) + (message "%s" message) (setq event (viper-read-key)) ;;(setq event (viper-read-event)) (setq key @@ -442,7 +442,11 @@ If SCOPE is nil, the user is asked to specify the scope." scope) viper-custom-file-name)) - (message msg) + ;; 2005-09-18 T06:41:22-0400 (Sunday) D. Goel + ;; From careful parsing of the above code, it looks like msg + ;; couldn't be nil when we reach here. Since it is a string, + ;; and a complicated one too, we might as well provide it a "%s" + (message "%s" msg) )) (setq new-elt diff --git a/lisp/emulation/ws-mode.el b/lisp/emulation/ws-mode.el index 41e8f5323a5..e677e5a20ff 100644 --- a/lisp/emulation/ws-mode.el +++ b/lisp/emulation/ws-mode.el @@ -691,7 +691,7 @@ in ws-last-errormessage for recovery with C-q w." This will only work for errors raised by WordStar mode functions." (interactive) (if ws-last-errormessage - (message ws-last-errormessage) + (message "%s" ws-last-errormessage) (message "No WordStar error yet."))) (defun ws-kill-eol () -- 2.39.5