diff options
-rw-r--r-- | src/nvim/ex_cmds.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/nvim/ex_cmds.c b/src/nvim/ex_cmds.c index 9a2b683bac..f50fb49f71 100644 --- a/src/nvim/ex_cmds.c +++ b/src/nvim/ex_cmds.c @@ -5324,13 +5324,11 @@ static void helptags_one(char_u *const dir, const char_u *const ext, FreeWild(filecount, files); - if (!got_int) { + if (!got_int && ga.ga_data != NULL) { /* * Sort the tags. */ - if (ga.ga_data != NULL) { - sort_strings((char_u **)ga.ga_data, ga.ga_len); - } + sort_strings((char_u **)ga.ga_data, ga.ga_len); /* * Check for duplicates. |