From 84621b7162b84bffeb5e46bf975ccd7318ad7cfb Mon Sep 17 00:00:00 2001 From: Lars Magne Ingebrigtsen Date: Mon, 2 May 2011 04:33:11 +0200 Subject: [PATCH] Decode &_ => SPC in the reply. --- lisp/server.el | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/lisp/server.el b/lisp/server.el index ab7dd409736..c421ee09812 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -1487,8 +1487,8 @@ only these files will be asked to be saved." (defun server-eval-at (server form) "Eval FORM on Emacs Server SERVER." (let ((auth-file (expand-file-name server server-auth-dir)) - ;;(coding-system-for-read 'binary) - ;;(coding-system-for-write 'binary) + (coding-system-for-read 'binary) + (coding-system-for-write 'binary) address port secret process) (unless (file-exists-p auth-file) (error "No such server definition: %s" auth-file)) @@ -1516,8 +1516,12 @@ only these files will be asked to be saved." (goto-char (point-min)) ;; If the result is nil, there's nothing in the buffer. If the ;; result is non-nil, it's after "-print ". - (and (search-forward "\n-print" nil t) - (read (current-buffer)))))) + (when (search-forward "\n-print" nil t) + (let ((start (point))) + (while (search-forward "&_" nil t) + (replace-match " " t t)) + (goto-char start) + (read (current-buffer))))))) (provide 'server) -- 2.39.2