diff options
Diffstat (limited to 'src/nvim/usercmd.c')
-rw-r--r-- | src/nvim/usercmd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/usercmd.c b/src/nvim/usercmd.c index 79f897f020..7856fcd0ba 100644 --- a/src/nvim/usercmd.c +++ b/src/nvim/usercmd.c @@ -422,10 +422,10 @@ char *get_user_cmd_complete(expand_T *xp, int idx) int cmdcomplete_str_to_type(const char *complete_str) { - if (strncmp(complete_str, "custom,", 7) == 0) { + if (strncmp(complete_str, S_LEN("custom,")) == 0) { return EXPAND_USER_DEFINED; } - if (strncmp(complete_str, "customlist,", 11) == 0) { + if (strncmp(complete_str, S_LEN("customlist,")) == 0) { return EXPAND_USER_LIST; } @@ -1056,7 +1056,7 @@ void ex_delcommand(exarg_T *eap) const char *arg = eap->arg; bool buffer_only = false; - if (strncmp(arg, "-buffer", 7) == 0 && ascii_iswhite(arg[7])) { + if (strncmp(arg, S_LEN("-buffer")) == 0 && ascii_iswhite(arg[7])) { buffer_only = true; arg = skipwhite(arg + 7); } |