]> git.eshelyaron.com Git - emacs.git/commitdiff
* test/lisp/simple-tests.el (with-shell-command-dont-erase-buffer):
authorMichael Albinus <michael.albinus@gmx.de>
Mon, 27 Apr 2020 08:36:33 +0000 (10:36 +0200)
committerMichael Albinus <michael.albinus@gmx.de>
Mon, 27 Apr 2020 08:36:33 +0000 (10:36 +0200)
Use `shell-quote-argument' instead of quoting 'like this'.

test/lisp/simple-tests.el

index b23b0804575b7eb447e6a22369394310a5718cf7..03f7260f551b8ce4fba6fa7e56fd876bce6ba593 100644 (file)
@@ -724,8 +724,9 @@ See Bug#21722."
             (,output-buf (if ,output-buffer-is-current ,caller-buf
                            (generate-new-buffer "output-buf")))
             (emacs (expand-file-name invocation-name invocation-directory))
-            (,command (format "%s -Q --batch --eval '(princ %S)'"
-                              emacs ,str))
+            (,command
+             (format "%s -Q --batch --eval %s"
+                     emacs (shell-quote-argument (format "(princ %S)" ,str))))
             (inhibit-message t))
        (unwind-protect
            ;; Feature must work the same regardless how we specify the 2nd arg of `shell-command', ie,