diff options
author | Matthieu Coudron <mattator@gmail.com> | 2020-06-06 02:05:49 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-06 02:05:49 +0200 |
commit | 33dafc4f0f21f763dac8f6bdbd27117666f908c5 (patch) | |
tree | 179301040b52babddbe60001bc5c9b467edc310a /src/nvim/ex_getln.c | |
parent | fca471d8e2573c2351151051a2d2c6eee0b2243b (diff) | |
parent | 9538a7895cb6af2312a39c4c0710ace638309914 (diff) | |
download | rneovim-33dafc4f0f21f763dac8f6bdbd27117666f908c5.tar.gz rneovim-33dafc4f0f21f763dac8f6bdbd27117666f908c5.tar.bz2 rneovim-33dafc4f0f21f763dac8f6bdbd27117666f908c5.zip |
Merge pull request #12413 from janlazo/vim-8.2.0089
[RDY]vim-patch:8.0.1564,8.1.{917,1895,2018,2335},8.2.{89,491,873,892,905}
Diffstat (limited to 'src/nvim/ex_getln.c')
-rw-r--r-- | src/nvim/ex_getln.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/ex_getln.c b/src/nvim/ex_getln.c index b799e86ff7..56a8f56753 100644 --- a/src/nvim/ex_getln.c +++ b/src/nvim/ex_getln.c @@ -5361,12 +5361,12 @@ void globpath(char_u *path, char_u *file, garray_T *ga, int expand_options) // Concatenate new results to previous ones. ga_grow(ga, num_p); + // take over the pointers and put them in "ga" for (int i = 0; i < num_p; i++) { - ((char_u **)ga->ga_data)[ga->ga_len] = vim_strsave(p[i]); + ((char_u **)ga->ga_data)[ga->ga_len] = p[i]; ga->ga_len++; } - - FreeWild(num_p, p); + xfree(p); } } } |