aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/help.c
diff options
context:
space:
mode:
authordundargoc <gocdundar@gmail.com>2022-11-26 18:57:46 +0100
committerdundargoc <gocdundar@gmail.com>2022-11-28 14:53:35 +0100
commit3b96ccf7d35be90e49029dec76344d3d92ad91dc (patch)
treef4768eb7d7be52402ccd55e3e4e04aecceab3e42 /src/nvim/help.c
parentb2bb3973d9c7f25acfead2718d74fcf5b1e4551e (diff)
downloadrneovim-3b96ccf7d35be90e49029dec76344d3d92ad91dc.tar.gz
rneovim-3b96ccf7d35be90e49029dec76344d3d92ad91dc.tar.bz2
rneovim-3b96ccf7d35be90e49029dec76344d3d92ad91dc.zip
refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
Diffstat (limited to 'src/nvim/help.c')
-rw-r--r--src/nvim/help.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/help.c b/src/nvim/help.c
index 8930f74e7f..cdd930203f 100644
--- a/src/nvim/help.c
+++ b/src/nvim/help.c
@@ -591,7 +591,7 @@ void cleanup_help_tags(int num_file, char **file)
for (j = 0; j < num_file; j++) {
if (j != i
&& (int)strlen(file[j]) == len + 3
- && STRNCMP(file[i], file[j], len + 1) == 0) {
+ && strncmp(file[i], file[j], (size_t)len + 1) == 0) {
break;
}
}
@@ -1041,7 +1041,7 @@ static void helptags_one(char *dir, const char *ext, const char *tagfname, bool
// Write the tags into the file.
for (int i = 0; i < ga.ga_len; i++) {
s = ((char **)ga.ga_data)[i];
- if (STRNCMP(s, "help-tags\t", 10) == 0) {
+ if (strncmp(s, "help-tags\t", 10) == 0) {
// help-tags entry was added in formatted form
fputs(s, fd_tags);
} else {
@@ -1122,7 +1122,7 @@ static void do_helptags(char *dirname, bool add_help_tags, bool ignore_writeerr)
// Did we find this language already?
for (j = 0; j < ga.ga_len; j += 2) {
- if (STRNCMP(lang, ((char_u *)ga.ga_data) + j, 2) == 0) {
+ if (strncmp(lang, ((char *)ga.ga_data) + j, 2) == 0) {
break;
}
}
@@ -1170,7 +1170,7 @@ void ex_helptags(exarg_T *eap)
bool add_help_tags = false;
// Check for ":helptags ++t {dir}".
- if (STRNCMP(eap->arg, "++t", 3) == 0 && ascii_iswhite(eap->arg[3])) {
+ if (strncmp(eap->arg, "++t", 3) == 0 && ascii_iswhite(eap->arg[3])) {
add_help_tags = true;
eap->arg = skipwhite(eap->arg + 3);
}