From 4219b69145f13e95eadb5a666cb02b482bdd395b Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Mon, 25 May 2015 14:13:18 -0400 Subject: input: stream_set_blocking(): libuv impl - Create a private libuv loop instead of re-using uv_default_loop(), to avoid conflict[1] with existing watcher(s) on the fd. - Expose the global "input" fd as a getter instead of a mutable global. [1] .deps/build/src/libuv/src/unix/core.c:833: uv__io_stop: Assertion `loop->watchers[w->fd] == w' failed. --- src/nvim/misc1.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/nvim/misc1.c') diff --git a/src/nvim/misc1.c b/src/nvim/misc1.c index 13e5f273e0..0737caec5d 100644 --- a/src/nvim/misc1.c +++ b/src/nvim/misc1.c @@ -2679,6 +2679,7 @@ void preserve_exit(void) // Prevent repeated calls into this method. if (really_exiting) { + stream_set_blocking(input_global_fd(), true); //normalize stream (#2598) exit(2); } @@ -2699,7 +2700,6 @@ void preserve_exit(void) } ml_close_all(false); // close all memfiles, without deleting - stream_set_blocking(global_input_fd, true); //normalize stream (#2598) mch_errmsg("Vim: Finished.\n"); -- cgit