]> git.eshelyaron.com Git - emacs.git/commitdiff
(server-start): Check `server-process' is non-nil
authorJohn Paul Wallington <jpw@pobox.com>
Fri, 25 Jul 2003 12:16:18 +0000 (12:16 +0000)
committerJohn Paul Wallington <jpw@pobox.com>
Fri, 25 Jul 2003 12:16:18 +0000 (12:16 +0000)
before killing it to avoid killing current buffer's process.

lisp/server.el

index 71e2463c595663499416ba2153291c15b319b30a..36cad64dde5de10783d1a73ed5ab15032262e732 100644 (file)
@@ -249,7 +249,8 @@ Prefix arg means just kill any existing server communications subprocess."
   ;; Make sure there is a safe directory in which to place the socket.
   (server-ensure-safe-dir (file-name-directory server-socket-name))
   ;; kill it dead!
-  (condition-case () (delete-process server-process) (error nil))
+  (if server-process
+      (condition-case () (delete-process server-process) (error nil)))
   ;; Delete the socket files made by previous server invocations.
   (condition-case () (delete-file server-socket-name) (error nil))
   ;; If this Emacs already had a server, clear out associated status.