aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/misc1.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2015-05-25 14:13:18 -0400
committerJustin M. Keyes <justinkz@gmail.com>2015-05-27 09:34:04 -0400
commit4219b69145f13e95eadb5a666cb02b482bdd395b (patch)
tree5684a6cb585e60372d41144a4ae13eee8aaab710 /src/nvim/misc1.c
parent8a782f1699e2a59a3f3e91f6d7c35a3312b82b41 (diff)
downloadrneovim-4219b69145f13e95eadb5a666cb02b482bdd395b.tar.gz
rneovim-4219b69145f13e95eadb5a666cb02b482bdd395b.tar.bz2
rneovim-4219b69145f13e95eadb5a666cb02b482bdd395b.zip
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.
Diffstat (limited to 'src/nvim/misc1.c')
-rw-r--r--src/nvim/misc1.c2
1 files changed, 1 insertions, 1 deletions
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");