Vim-fork focused on extensibility and usability
Go to file
Justin M. Keyes b182f247ec eval/term_write(): Skip writes if stream was closed.
If the backing stream for a :terminal was closed (e.g. if the shell exits
unexpectedly) there may be pending input on the loop which will be processed
before the terminal close event (which is queued on the same loop).

terminal_send checks term->closed but this does not reflect the state of the
underlying streams. The terminal.c module in fact has no knowledge of the
streams (this seems intentional: it is abstracted as TerminalOption.write_cb).

The SIGCHLD handler (pty_process_unix.c) is executed immediately, and it
triggers a stream teardown so Stream.closed=false (TerminalJobData.in.closed).
When the pending writes are handled by eval.c:term_write, wstream_write() aborts
because it sees the closed Stream.

To avoid that, this commit checks Stream.closed in eval:term_write() before writing
to the WStream. (As hinted above, we cannot do this in terminal:terminal_send()
because that module cannot inspect the underlying streams.)

References #5445
https://github.com/neovim/neovim/pull/5445#issuecomment-252529766
2016-10-12 04:33:53 +02:00
.ci eval: use gperf to generate the hash of builtin functions 2016-08-31 21:57:04 +02:00
cmake functionaltest: Create lua helper for os.tmpname() 2016-08-31 11:32:28 +01:00
config config: Allow setting USERNAME/HOSTNAME from the environment 2016-10-08 14:22:36 -04:00
contrib Makefile: add PREFIX variable 2016-10-08 18:39:35 +02:00
man man: fix description of XDG_DATA_HOME (#5120) 2016-07-27 08:52:35 -04:00
runtime UpdateRemotePlugins: Discard duplicate paths. (#5464) 2016-10-12 01:04:59 +02:00
scripts api: add blanket implementation of "since" 2016-09-27 16:54:55 +02:00
src eval/term_write(): Skip writes if stream was closed. 2016-10-12 04:33:53 +02:00
test test/terminal: Cover race when :term shell process exits. 2016-10-12 04:33:53 +02:00
third-party third-party: Bump luv to v1.9.1-0 2016-09-10 18:43:05 +01:00
unicode Update unicode files 2016-09-24 14:03:22 -04:00
.editorconfig add .editorconfig 2016-02-23 18:03:27 +09:00
.gitignore ignore .res files generated by the tests in testdir 2016-08-11 02:14:02 -04:00
.travis.yml ci: .travis.yml: Minimize scope of osx_image directive. (#5420) 2016-10-02 03:37:17 +02:00
appveyor.yml build: Refactor appveyor/Windows scripts (#5244) 2016-08-26 01:38:46 -04:00
BACKERS.md Update backer URL 2015-11-11 19:50:33 -08:00
CMakeLists.txt Disable use of jemalloc in OpenBSD 2016-09-10 18:43:04 +01:00
CONTRIBUTING.md doc: CONTRIBUTING.md (#5239) 2016-08-23 23:49:09 -04:00
ISSUE_TEMPLATE.md doc: precision, concision, elision 2016-06-03 17:11:10 -04:00
LICENSE LICENSE: add LuaJIT notice. #899 2014-06-30 13:59:56 -04:00
Makefile Makefile: add PREFIX variable 2016-10-08 18:39:35 +02:00
README.md doc 2016-08-10 00:47:17 -04:00

Neovim

Website | Community | Wiki | Documentation | Mailing List | Twitter | Bountysource

Travis Build Status AppVeyor Build status Pull requests waiting for review Coverage Status Coverity Scan Build Clang Scan Build Gitter chat

Neovim is a project that seeks to aggressively refactor Vim in order to:

  • Simplify maintenance and encourage contributions
  • Split the work between multiple developers
  • Enable the implementation of new/modern UIs without modifications to the core
  • Improve extensibility with a new plugin architecture

For more details, see the wiki!

Throughput Graph

What's been done so far

See :help nvim-features for a comprehensive list.

What's being worked on now

See the Roadmap.

How do I get it?

There is a formula for OSX/homebrew, a PKGBUILD for Arch Linux, RPM, deb, and more. See the wiki!

License

Neovim is licensed under the terms of the Apache 2.0 license, except for parts that were contributed under the Vim license.

  • Contributions committed before b17d96 remain under the Vim license.

  • Contributions committed after b17d96 are licensed under Apache 2.0 unless those contributions were copied from Vim (identified in the commit logs by the vim-patch token).

See LICENSE for details.

Vim is Charityware.  You can use and copy it as much as you like, but you are
encouraged to make a donation for needy children in Uganda.  Please see the
kcc section of the vim docs or visit the ICCF web site, available at these URLs:

        http://iccf-holland.org/
        http://www.vim.org/iccf/
        http://www.iccf.nl/

You can also sponsor the development of Vim.  Vim sponsors can vote for
features.  The money goes to Uganda anyway.