diff options
author | Daniel Hahler <git@thequod.de> | 2019-09-11 13:48:09 +0200 |
---|---|---|
committer | Daniel Hahler <git@thequod.de> | 2019-09-25 05:47:12 +0200 |
commit | bb6b1267e7532e0c2e065c4e9b5552623062c70f (patch) | |
tree | 13d45634bdc69b34511fcf395d7ba618cc779c14 | |
parent | 227ef7162138a55657b013ae633978c54a1411a8 (diff) | |
download | rneovim-bb6b1267e7532e0c2e065c4e9b5552623062c70f.tar.gz rneovim-bb6b1267e7532e0c2e065c4e9b5552623062c70f.tar.bz2 rneovim-bb6b1267e7532e0c2e065c4e9b5552623062c70f.zip |
Revert "win/os_env_exists(): workaround libuv bug #10734"
This reverts commit 278c5d452c2cbc436a9cc317407ae6021a226c3a.
-rw-r--r-- | src/nvim/os/env.c | 3 | ||||
-rw-r--r-- | test/functional/eval/environ_spec.lua | 1 |
2 files changed, 1 insertions, 3 deletions
diff --git a/src/nvim/os/env.c b/src/nvim/os/env.c index 54fdd7961c..13853016d1 100644 --- a/src/nvim/os/env.c +++ b/src/nvim/os/env.c @@ -102,9 +102,6 @@ bool os_env_exists(const char *name) assert(r != UV_EINVAL); if (r != 0 && r != UV_ENOENT && r != UV_ENOBUFS) { ELOG("uv_os_getenv(%s) failed: %d %s", name, r, uv_err_name(r)); -#ifdef WIN32 - return (r == UV_UNKNOWN); -#endif } return (r == 0 || r == UV_ENOBUFS); } diff --git a/test/functional/eval/environ_spec.lua b/test/functional/eval/environ_spec.lua index 4c2adcf1bf..54d2dc960b 100644 --- a/test/functional/eval/environ_spec.lua +++ b/test/functional/eval/environ_spec.lua @@ -10,6 +10,7 @@ describe('environment variables', function() eq("", environ()['EMPTY_VAR']) eq(nil, environ()['DOES_NOT_EXIST']) end) + it('exists() handles empty env variable', function() clear({env={EMPTY_VAR=""}}) eq(1, exists('$EMPTY_VAR')) |