Fix line/column number positioning in emacsclient. (Reported by Han Boetes.)
authorKaroly Lorentey <lorentey@elte.hu>
Sun, 20 Feb 2005 20:15:41 +0000 (20:15 +0000)
committerKaroly Lorentey <lorentey@elte.hu>
Sun, 20 Feb 2005 20:15:41 +0000 (20:15 +0000)
* lisp/server.el (server-process-filter): When processing -position
  command, don't change the request string until the parameters are
  extracted.

git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-297

lisp/server.el

index d8bd83b..f0ce3c6 100644 (file)
@@ -677,9 +677,9 @@ The following commands are accepted by the client:
 
                 ;; -position LINE:COLUMN:  Set point to the given position in the next file.
                 ((and (equal "-position" arg) (string-match "\\+\\([0-9]+\\):\\([0-9]+\\) " request))
-                 (setq request (substring request (match-end 0))
-                       lineno (string-to-int (match-string 1 request))
-                       columnno (string-to-int (match-string 2 request))))
+                 (setq lineno (string-to-int (match-string 1 request))
+                       columnno (string-to-int (match-string 2 request))
+                       request (substring request (match-end 0))))
 
                 ;; -file FILENAME:  Load the given file.
                 ((and (equal "-file" arg) (string-match "\\([^ ]+\\) " request))