aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os
Commit message (Collapse)AuthorAge
...
* api/nvim_get_mode: Use child-queue instead of "priority".Justin M. Keyes2017-04-28
|
* input.c: Process only safe events before blocking.Justin M. Keyes2017-04-28
| | | | | Introduce multiqueue_process_priority() to process only events at or above a certain priority.
* api: nvim_get_mode()Justin M. Keyes2017-04-28
| | | | | | | | | | | | | | | | | | | | | | | | | | Asynchronous API functions are served immediately, which means pending input could change the state of Nvim shortly after an async API function result is returned. nvim_get_mode() is different: - If RPCs are known to be blocked, it responds immediately (without flushing the input/event queue) - else it is handled just-in-time before waiting for input, after pending input was processed. This makes the result more reliable (but not perfect). Internally this is handled as a special case, but _semantically_ nothing has changed: API users never know when input flushes, so this internal special-case doesn't violate that. As far as API users are concerned, nvim_get_mode() is just another asynchronous API function. In all cases nvim_get_mode() never blocks for more than the time it takes to flush the input/event queue (~µs). Note: This doesn't address #6166; nvim_get_mode() will provoke #6166 if e.g. `d` is operator-pending. Closes #6159
* test/fs: sanity check for literal "~" directory (#6579)Justin M. Keyes2017-04-24
| | | | If the CWD contains a directory with the literal name "~" then the tests will have bogus failures.
* os_term_is_nice: Return true for rxvt and iTerm.Justin M. Keyes2017-04-22
|
* Merge #6550 from ZyX-I/pvs-check-commentJustin M. Keyes2017-04-20
|\
| * *: Add comment to all C filesZyX2017-04-19
| |
* | vim-patch:7.4.2209James McCoy2017-04-19
|/ | | | | | | | Problem: Cannot map <M-">. (Stephen Riehm) Solution: Solve the memory access problem in another way. (Dominique Pelle) Allow for using <M-\"> in a string. https://github.com/vim/vim/commit/35a4cfa200917dd171b1fff3cd5b6cee9add673d
* os/env: Fix “invalid pointer to local” false positiveZyX2017-04-16
|
* fileio: Silence “!= identical subexpressions” warningZyX2017-04-16
|
* os/shell: Remove FUNC_ATTR_MALLOC from shell_build_argvZyX2017-04-15
| | | Returns an array of allocated strings.
* os/fileio: Remove FUNC_ATTR_MALLOC for file_open_newZyX2017-04-15
| | | fp contains pointer to rbuffer
* win: os_shell_is_cmdexe() + testsJustin M. Keyes2017-04-12
|
* win: defaults: 'shellredir', 'shellxquote', 'shellxescape'Justin M. Keyes2017-04-12
|
* win: os_get_hostname() #5416 (#6413)Justin M. Keyes2017-04-07
|
* 'guicursor': Disable by default for unknown terminals.Justin M. Keyes2017-04-04
| | | | | | | User can still set guicursor explicitly in init.vim. Closes #5990 Closes #6403
* fileio: Refactor msg_add_fname to something which needs no commentsZyX2017-04-03
|
* eval: Make writefile() able to disable fsync()ZyX2017-04-02
|
* eval,fileio: Omit additional fsync() callZyX2017-04-01
| | | | Fixes #6420
* Merge pull request #6397 from jamessan/coverityJames McCoy2017-03-31
|\ | | | | Fix latest Coverity issues
| * coverity/161195: Increase scope of exe_nameJames McCoy2017-03-29
| | | | | | | | | | Since exe_name is a stack allocated array, we need it to be in scope for the lifetime that vim_path points to it.
* | win: tempname(): Use $TMPDIR if defined.Justin M. Keyes2017-03-30
|/
* eval: Move part of dictwatcher* functions to eval/typvalZyX2017-03-29
|
* *: Fix some Windows-specific warningsZyX2017-03-29
| | | | Also fixed an error in path_fnamecmp().
* eval: Move remaining get_tv_string* functions to eval/typval.cZyX2017-03-29
|
* eval,*: Move get_tv_string to typval.cZyX2017-03-29
| | | | Function was renamed and changed to return `const char *`.
* ci: Check that `#include "*.h"` works as a single includeEiichi NISHINA2017-03-27
| | | | | | | | | | | Lesser form of include-what-you-use: at least guarantees that header file did not forget to include something through some other included file. Activate run_single_includes_tests on CI. Fix some IWYU violations. References #5321
* os_set_cloexec: Fix condition. #5986Justin M. Keyes2017-03-17
| | | | Also: skip Test_undo_del_chars the right way. #6287
* terminal: Support extra arguments in 'shell'. #4504Jack Bracewell2017-03-17
| | | | | | | | | | | | | Tokenize p_sh if used as default in ex_terminal(). Previously p_sh was used as the first arg in a list when calling termopen(), this would try to call an untokenized version of shell, meaning if you had an argument in 'shell': set shell=/bin/bash\ --login the command would fail. Helped-by: oni-link <knil.ino@gmail.com> Closes #3999
* job-control: set CLOEXEC on pty processes. #5986Matthew Malcomson2017-03-17
| | | | | Before this change, new processes started with libuv prevented SIGHUP from reaching pty processes (by keeping the ptmx file descriptor open).
* vim_getenv: $VIMRUNTIME fallback: ../share/nvim/runtime (#6223)Justin M. Keyes2017-03-06
| | | | | | | | | Do this on all systems, so that portable builds work everywhere. This allows us to ship archives with this folder structure: bin/nvim share/nvim/runtime then ./bin/nvim works without the user needing to explicitly set VIMRUNTIME.
* os/fileio: Support appending to a fileZyX2017-02-14
|
* os/fileio: Allow certain failures during file_fsyncZyX2017-02-14
| | | | | | According to the documentation fsync() may fail with EROFS or EINVAL if “file descriptor is bound to a special file which does not support synchronization” (e.g. /dev/stderr). This condition is completely valid in this case since main point of `file_fsync()` is dumping buffered input.
* os/*: Use os_buf instead of NameBuff, IObuff.Justin M. Keyes2017-02-12
|
* coverity/155968: resource leakJustin M. Keyes2017-02-09
|
* process_spawn: Return status code (#6075)Justin M. Keyes2017-02-09
|
* vim-patch:8.0.0275Justin M. Keyes2017-02-06
| | | | | | | | Problem: When checking for CTRL-C typed the GUI may detect a screen resize and redraw the screen, causing trouble. Solution: Set updating_screen in ui_breakcheck(). https://github.com/vim/vim/commit/e3caa1109072b9655f8d5103c92efd73177f8577
* refactor: fix warningsJustin M. Keyes2017-02-04
|
* win: executable(): full path without extensionJustin M. Keyes2017-02-04
| | | | Absolute path is considered executable even *without* an extension.
* vim-patch:8.0.0280Justin M. Keyes2017-02-04
| | | | | | | | | | patch 8.0.0280: problem setting multi-byte environment var on MS-Windows Problem: On MS-Windows setting an environment variable with multi-byte strings does not work well. Solution: Use wputenv when possible. (Taro Muraoka, Ken Takata) 7c23d1d9d9cc
* win: Append process dir to $PATHJustin M. Keyes2017-02-04
| | | | | | | | This allows executables to be found by :!, system(), and executable() if they live next to ("sibling" to) nvim.exe. This is what gvim on Windows does, and also matches the behavior of Win32 SearchPath(). https://github.com/vim/vim/blob/c4a249a736d40ec54794827ef95804c225d0e38f/src/os_win32.c#L354-L370
* win: executable()Justin M. Keyes2017-02-04
| | | | | Windows: prepend `".;"` to PATH, as Vim does. https://github.com/vim/vim/blob/c4a249a736d40ec54794827ef95804c225d0e38f/src/os_win32.c#L1916
* refactor: Remove strncpy/STRNCPY. (#6008)Justin M. Keyes2017-01-26
| | | | | | | | | | | | | | | Closes #731 References #851 Note: This does not remove some intentional legacy usages of strncpy. - memcpy isn't equivalent because it doesn't check the string length of `src`, and doesn't zero-out the remainder of `dst`. - xstrlcpy isn't equivalent because it doesn't zero-out the remainder of `dst`. Some Vim logic depends on that (e.g. ex_append which calls vim_strnsave). Helped-by: Douglas Schneider <ds3@ualberta.ca> Helped-by: oni-link <knil.ino@gmail.com> Helped-by: James McCoy <jamessan@jamessan.com>
* refactor: strlcat instead of str{n}cat.cztchoice2017-01-23
| | | | | | | | | | Add xstrlcat function. Closes #3042 References #988 References #1069 coverity: 71530, 71531, 71532
* test: expand_env_esc()Justin M. Keyes2017-01-21
| | | | | | Test expand_env_esc() using the same parameters reported in #3725. Closes #3725
* input_enqueue(): Fix length calculation. (#5981)Justin M. Keyes2017-01-20
| | | Ref: https://github.com/neovim/neovim/issues/5885#issuecomment-273614373
* win: fix warningsJustin M. Keyes2017-01-19
|
* Windows: vim_getenv(): Find runtime relative to nvim. #3303 (#5929)Justin M. Keyes2017-01-11
| | | | | | | | | | | | In Windows we cannot rely on absolute install paths to point to the location of the runtime. Vim uses the path of the current binary as a possible location for the runtime folder. In Neovim the install location places the runtime folder in ../share/nvim/runtime. In Vim this logic is guarded by USE_EXE_NAME, which is defined for win32 and macOS. TODO: We may need to incorporate similar logic for macOS: https://github.com/vim/vim/blob/0cdb72aa38c4a0140c94d56bf8bc17cb30260ebf/src/misc1.c#L4287-L4308
* XDG: Windows: resolve $LOCALAPPDATA, $TEMP (#5278)Rui Abreu Ferreira2017-01-08
| | | | | | | | | | After #4964 environment variables in the XDG "fallback" table are no longer expanded. Fallback to correctly expanded $LOCALAPPDATA, $TEMP. If that fails (unlikely), fallback to hard-coded paths (e.g. ~/AppData/Local). Closes #5255
* time.c: os_microdelay(): Let input cancel the delay. #5830Michael Schupikov2017-01-06
| | | | Closes #5397