emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] 02/07: [gnugo int] Avoid variable FO RMAT for ‘message’.


From: Thien-Thi Nguyen
Subject: [elpa] 02/07: [gnugo int] Avoid variable FO RMAT for ‘message’.
Date: Thu, 06 Feb 2014 10:39:44 +0000

ttn pushed a commit to branch ttn-gnugo
in repository elpa.

commit a59f3d5144e2ad5bec05adb99a8b7da73cc8a868
Author: Thien-Thi Nguyen <address@hidden>
Date:   Wed Feb 5 11:19:10 2014 +0100

    [gnugo int] Avoid variable FORMAT for ‘message’.
    
    We don't want weirdness should the variable value include ‘?%’.
    
    * packages/gnugo/gnugo.el (gnugo-command): Don't use var as
    ‘message’ first arg; instead say ‘(message "%s" ...)’.
---
 packages/gnugo/ChangeLog |    9 +++++++++
 packages/gnugo/gnugo.el  |    4 ++--
 2 files changed, 11 insertions(+), 2 deletions(-)

diff --git a/packages/gnugo/ChangeLog b/packages/gnugo/ChangeLog
index e060ae2..af50d1e 100644
--- a/packages/gnugo/ChangeLog
+++ b/packages/gnugo/ChangeLog
@@ -1,3 +1,12 @@
+2014-02-05  Thien-Thi Nguyen  <address@hidden>
+
+       [gnugo int] Avoid variable FORMAT for ‘message’.
+
+       We don't want weirdness should the variable value include ‘?%’.
+
+       * gnugo.el (gnugo-command): Don't use var as
+       ‘message’ first arg; instead say ‘(message "%s" ...)’.
+
 2014-02-03  Thien-Thi Nguyen  <address@hidden>
 
        [gnugo] Indicate buffer not modified after save.
diff --git a/packages/gnugo/gnugo.el b/packages/gnugo/gnugo.el
index f69078b..7d82e29 100644
--- a/packages/gnugo/gnugo.el
+++ b/packages/gnugo/gnugo.el
@@ -1528,12 +1528,12 @@ NOTE: At this time, GTP command handling specification 
is still
         (let* ((ans (cdr (gnugo-synchronous-send/return command)))
                (where (plist-get spec :output)))
           (if (string-match "unknown.command" ans)
-              (message ans)
+              (message "%s" ans)
             (cond ((functionp where) (funcall where ans))
                   ((eq :discard where) (message ""))
                   ((or (eq :message where)
                        (not (string-match "\n" ans)))
-                   (message ans))
+                   (message "%s" ans))
                   (t (switch-to-buffer "*gnugo command output*")
                      (erase-buffer)
                      (insert ans)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]