From 8fcf3df9395a3b1196fd5c95aeebba9e75f69247 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Johan=20Bockg=C3=A5rd?= Date: Thu, 18 Aug 2016 21:25:11 +0200 Subject: [PATCH] Fix bug in --eval reply message from server * lisp/server.el (server-reply-print): Fix check for truncated quote sequence at end of message. Problem reported in: http://lists.gnu.org/archive/html/emacs-devel/2016-08/msg00101.html --- lisp/server.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/server.el b/lisp/server.el index e4cf4312570..53009849e25 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -784,7 +784,7 @@ This handles splitting the command if it would be bigger than ;; We have to split the string (setq part (substring qtext 0 (- server-msg-size (length prefix) 1))) ;; Don't split in the middle of a quote sequence - (if (string-match "\\(^\\|[^&]\\)\\(&&\\)+$" part) + (if (string-match "\\(^\\|[^&]\\)&\\(&&\\)*$" part) ;; There is an uneven number of & at the end (setq part (substring part 0 -1))) (setq qtext (substring qtext (length part))) -- 2.39.5