-
-
Notifications
You must be signed in to change notification settings - Fork 192
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
@@@ LSP: Prevent deadlock with synchronous client
@@@ winders @@@ perf. lots of copying. sadge. =[ @@@ test LSP server manually If an LSP client sends a bunch of requests, but does not read from quick-lint-js' stdout, quick-lint-js can hang in pipe_reader::write. (This came up when writing some benchmarks. My LSP client naively made a bunch of requests without reading responses during the requests.) Prevent this (unlikely) deadlock by switching stdout to non-blocking mode, buffering data in memory, and resuming reading from stdin as soon as possible. The current implementation is relatively inefficient. Data is copied many times. Maybe we'll clean this up in the future.
- Loading branch information
Showing
7 changed files
with
253 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.