aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
diff options
context:
space:
mode:
authorDaniel Hahler <git@thequod.de>2019-07-24 22:23:00 +0200
committerGitHub <noreply@github.com>2019-07-24 22:23:00 +0200
commitb8fcf62da9261e47821c5e3d369dc4fd58d2b721 (patch)
treeda9e717539657a8bf2b91807d64d72726c663c4f /src/nvim/eval.c
parent3566267e753996c441c220c8a109bb4f4b25225c (diff)
downloadrneovim-b8fcf62da9261e47821c5e3d369dc4fd58d2b721.tar.gz
rneovim-b8fcf62da9261e47821c5e3d369dc4fd58d2b721.tar.bz2
rneovim-b8fcf62da9261e47821c5e3d369dc4fd58d2b721.zip
vim-patch:8.1.1740: exepath() doesn't work for "bin/cat" (#10556)
Problem: Exepath() doesn't work for "bin/cat". Solution: Check for any path separator. (Daniel Hahler, closes vim/vim#4724, closes vim/vim#4710) https://github.com/vim/vim/commit/d08b8c4c04db9433340df38d21f0e26878f28421 Fixes https://github.com/neovim/neovim/issues/10554.
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r--src/nvim/eval.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 1bddafbee3..4e5c310fb6 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -8465,10 +8465,7 @@ static void f_executable(typval_T *argvars, typval_T *rettv, FunPtr fptr)
const char *name = tv_get_string(&argvars[0]);
// Check in $PATH and also check directly if there is a directory name
- rettv->vval.v_number = (
- os_can_exe(name, NULL, true)
- || (gettail_dir(name) != name
- && os_can_exe(name, NULL, false)));
+ rettv->vval.v_number = os_can_exe(name, NULL, true);
}
typedef struct {