From 4f6e152e1c5efc39a888f747ecca313a58f4375e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Felici=C3=A1n=20N=C3=A9meth?= Date: Thu, 16 Apr 2020 09:38:31 +0200 Subject: [PATCH] Fix #430: send shutdown and exit messages without arguments Fix regression introduced in 212a7f7b (#315). According to the LSP specification the exit notification and the shutdown request shouldn't have arguments ("params: void"). Note that jsonrpc.el send nil as null on the wire. * eglot.el (eglot-shutdown): Change back the arguments of :shutdown and :exit to nil. --- eglot.el | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/eglot.el b/eglot.el index fe06e0c9..3149cd5c 100644 --- a/eglot.el +++ b/eglot.el @@ -598,9 +598,8 @@ SERVER. ." (unwind-protect (progn (setf (eglot--shutdown-requested server) t) - (jsonrpc-request server :shutdown eglot--{} - :timeout (or timeout 1.5)) - (jsonrpc-notify server :exit eglot--{})) + (jsonrpc-request server :shutdown nil :timeout (or timeout 1.5)) + (jsonrpc-notify server :exit nil)) ;; Now ask jsonrpc.el to shut down the server. (jsonrpc-shutdown server (not preserve-buffers)) (unless preserve-buffers (kill-buffer (jsonrpc-events-buffer server)))))