diff options
author | jdrouhard <john@drouhard.dev> | 2022-08-01 16:39:23 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-02 05:39:23 +0800 |
commit | d4b9f8186d4a73a661a407efb63fe8abca2c4e88 (patch) | |
tree | 860623d28c8c877eee3e32f92b229202efb4aa8c /src/nvim/file_search.c | |
parent | e99de3f12f00662e8131fed9912792f6d43c4975 (diff) | |
download | rneovim-d4b9f8186d4a73a661a407efb63fe8abca2c4e88.tar.gz rneovim-d4b9f8186d4a73a661a407efb63fe8abca2c4e88.tar.bz2 rneovim-d4b9f8186d4a73a661a407efb63fe8abca2c4e88.zip |
vim-patch:9.0.0126 (#19612)
vim-patch:9.0.0126: expanding file names fails in dir with more than 255 entries
Problem: Expanding file names fails in directory with more than 255
entries.
Solution: Use an int instead of char_u to count. (John Drouhard,
closes vim/vim#10818)
https://github.com/vim/vim/commit/95fca12b0e8a351ce4416417323db24c63eb940a
Diffstat (limited to 'src/nvim/file_search.c')
-rw-r--r-- | src/nvim/file_search.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/file_search.c b/src/nvim/file_search.c index 810684eb61..ebefd1157c 100644 --- a/src/nvim/file_search.c +++ b/src/nvim/file_search.c @@ -86,7 +86,7 @@ typedef struct ff_stack { // of wc_part char **ffs_filearray; int ffs_filearray_size; - char_u ffs_filearray_cur; // needed for partly handled dirs + int ffs_filearray_cur; // needed for partly handled dirs /* to store status of partly handled directories * 0: we work on this directory for the first time @@ -860,8 +860,8 @@ char_u *vim_findfile(void *search_ctx_arg) #endif // push dir to examine rest of subdirs later - assert(i < UCHAR_MAX - 1); - stackp->ffs_filearray_cur = (char_u)(i + 1); + assert(i < INT_MAX); + stackp->ffs_filearray_cur = i + 1; ff_push(search_ctx, stackp); if (!path_with_url((char *)file_path)) { |