From f75feb67244c279e75a4e8c9996a72eed729d321 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Wed, 17 Apr 2019 11:47:29 +0300 Subject: cleanup cancellation Now that we explicitelly exit the reading loop on exit notification, we can assume that the sender is always alive --- crates/gen_lsp_server/src/stdio.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'crates/gen_lsp_server/src') diff --git a/crates/gen_lsp_server/src/stdio.rs b/crates/gen_lsp_server/src/stdio.rs index 5edfbc39c..2d6418400 100644 --- a/crates/gen_lsp_server/src/stdio.rs +++ b/crates/gen_lsp_server/src/stdio.rs @@ -27,9 +27,7 @@ pub fn stdio_transport() -> (Receiver, Sender, Threads) _ => false, }; - if let Err(_) = reader_sender.send(msg) { - break; - } + reader_sender.send(msg).unwrap(); if is_exit { break; -- cgit v1.2.3