]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix possibly buggy calls to `message'.
authorDeepak Goel <deego@gnufans.org>
Thu, 6 Dec 2007 00:17:56 +0000 (00:17 +0000)
committerDeepak Goel <deego@gnufans.org>
Thu, 6 Dec 2007 00:17:56 +0000 (00:17 +0000)
lisp/ChangeLog
lisp/apropos.el
lisp/complete.el
lisp/ediff.el
lisp/files.el
lisp/help.el
lisp/image-dired.el
lisp/simple.el

index d4b5237b479d3b02c5e7695c967a378ac0147758..733fba10ebe3e0704105fd6b4067160803af65df 100644 (file)
@@ -1,5 +1,23 @@
 2007-12-05  D. Goel  <deego3@gmail.com>
 
+       * simple.el (undo): Ditto.
+
+       * image-dired.el (image-dired-display-thumb-properties): Ditto.
+       (image-dired-modify-mark-on-thumb-original-file): Ditto.
+       (image-dired-dired-display-properties): Ditto.
+
+       * help.el (help-window-display-message): Ditto.
+
+       * files.el (hack-local-variables-confirm): Ditto.
+
+       * ediff.el (ediff-version): Ditto.
+
+       * complete.el (pc-chunk-after): Ditto.
+       (PC-temp-minibuffer-message): Ditto.
+
+       * apropos.el (apropos-command): `message' and `error': Ensure that first arg is
+       a format string.
+
        * emacs-lisp/find-func.el (find-library-name): Prefer files with
        ".el" suffix over "".
 
index 9fddf0103fbe75dfe56603c87c1014785d4ac5d7..f9720e1bcdb52cae4510623ce229e8392f89c542 100644 (file)
@@ -449,7 +449,7 @@ while a list of strings is used as a word list."
                          "command or function" "command"))
                     current-prefix-arg))
   (apropos-parse-pattern pattern)
-  (let ((message
+  (let ((message "%s"
         (let ((standard-output (get-buffer-create "*Apropos*")))
           (print-help-return-message 'identity))))
     (or do-all (setq do-all apropos-do-all))
index e1d0ef07df4127810812625675e6a022ba8adef9..b3a4928dd5359572b0c2702684a4f66df2308ce3 100644 (file)
@@ -381,9 +381,9 @@ of `minibuffer-completion-table' and the minibuffer contents.")
 ;; Returns the sequence of non-delimiter characters that follow regexp in string.
 (defun PC-chunk-after (string regexp)
   (if (not (string-match regexp string))
-      (let ((message (format "String %s didn't match regexp %s" string regexp)))
-       (message message)
-       (error message)))
+      (let ((message "String %s didn't match regexp %s"))
+       (message message string regexp)
+       (error message string regexp)))
   (let ((result (substring string (match-end 0))))
     ;; result may contain multiple chunks
     (if (string-match PC-delim-regex result)
@@ -869,7 +869,7 @@ GOTO-END is non-nil, however, it instead replaces up to END."
 (defun PC-temp-minibuffer-message (message)
   "A Lisp version of `temp_minibuffer_message' from minibuf.c."
   (cond (PC-not-minibuffer
-        (message message)
+        (message "%s" message)
         (sit-for 2)
         (message ""))
        ((fboundp 'temp-minibuffer-message)
index 5974f23d64a6fe47d5dac5770a25d85a1f868386..a53b93aee5bb863f17350978e817b218a17ad36f 100644 (file)
@@ -1423,7 +1423,7 @@ Uses `vc.el' or `rcs.el' depending on `ediff-version-control-package'."
 When called interactively, displays the version."
   (interactive)
   (if (interactive-p)
-      (message (ediff-version))
+      (message "%s" (ediff-version))
     (format "Ediff %s of %s" ediff-version ediff-date)))
 
 ;; info is run first, and will autoload info.el.
index 274b6b7cd01035a00269fd6134c0090f4674a99d..8d5fcfda8c298038a543e204bcd9d61658ece3ac 100644 (file)
@@ -2632,7 +2632,7 @@ n  -- to ignore the local variables list.")
                 (if offer-save '(?! ?y ?n ?\s ?\C-g) '(?y ?n ?\s ?\C-g)))
                done)
            (while (not done)
-             (message prompt)
+             (message "%s" prompt)
              (setq char (read-event))
              (if (numberp char)
                  (cond ((eq char ?\C-v)
index ac6af2d9e508fad35c6cf500ff1e0012f9644438..c6650e1cf21c1ca48844436b260b9c74f269933f 100644 (file)
@@ -1029,7 +1029,7 @@ scroll the \"other\" window."
           ".")
          (other ", \\[scroll-other-window] to scroll help.")
          (t ", \\[scroll-up] to scroll help."))))
-    (message
+    (message "%s"
      (substitute-command-keys (concat quit-part scroll-part)))))
 
 (defun help-window-setup-finish (window &optional reuse keep-frame)
index 82bfbfb20af9f0d893b2ec06257b6550ddb86496..cca9686f237b107a844781fb0705f14d973a3073 100644 (file)
@@ -1184,7 +1184,7 @@ comment."
                     ", "))
             (comment (get-text-property (point) 'comment)))
         (if file-name
-            (message
+             (message "%s"
              (image-dired-format-properties-string
               dired-buf
               file-name
@@ -1208,7 +1208,7 @@ dired."
     (if (not (and dired-buf file-name))
         (message "No image, or image with correct properties, at point.")
     (with-current-buffer dired-buf
-        (message file-name)
+        (message "%s" file-name)
         (setq file-name (file-name-nondirectory file-name))
         (goto-char (point-min))
         (if (search-forward file-name nil t)
@@ -2239,7 +2239,7 @@ non-nil."
                  ", "))
          (comment (image-dired-get-comment file)))
     (if file-name
-        (message
+        (message "%s"
          (image-dired-format-properties-string
           dired-buf
           file-name
index f49921e60dc754acfd1fe4b7d4206ef21f507d3c..22f29ab04643c116d3b18df300c8ce4d1b5e1ac0 100644 (file)
@@ -1633,7 +1633,7 @@ as an argument limits undo to changes within the current region."
         (delete-auto-save-file-if-necessary recent-save))
     ;; Display a message announcing success.
     (if message
-       (message message))))
+       (message "%s" message))))
 
 (defun buffer-disable-undo (&optional buffer)
   "Make BUFFER stop keeping undo information.