# HG changeset patch # User Juanma Barranquero # Date 1174478552 0 # Node ID ab479de41b2988cb11bbb67f3a186941db0263ec # Parent a91fecca26d3b00367baa724ac60656c7abab074 (server-process-filter): Cancel any pending isearch. diff -r a91fecca26d3 -r ab479de41b29 lisp/server.el --- a/lisp/server.el Wed Mar 21 07:15:44 2007 +0000 +++ b/lisp/server.el Wed Mar 21 12:02:32 2007 +0000 @@ -414,6 +414,16 @@ (run-with-timer 0 nil (lexical-let ((proc proc)) (lambda () (server-process-filter proc "")))) (top-level)) + (condition-case nil + ;; If we're running isearch, we must abort it to allow Emacs to + ;; display the buffer and switch to it. + (mapc #'(lambda (buffer) + (with-current-buffer buffer + (when (bound-and-true-p isearch-mode) + (isearch-cancel)))) + (buffer-list)) + ;; Signaled by isearch-cancel + (quit (message nil))) ;; If the input is multiple lines, ;; process each line individually. (while (string-match "\n" string)