strings: Enable -Wconvert.

This commit is contained in:
Scott Prager
2014-11-19 15:23:11 -05:00
parent ecf81c3f20
commit f75de5e671
4 changed files with 27 additions and 29 deletions

View File

@@ -1813,10 +1813,10 @@ void ex_loadkeymap(exarg_T *eap)
if ((*p != '"') && (*p != NUL)) {
kmap_T *kp = GA_APPEND_VIA_PTR(kmap_T, &curbuf->b_kmap_ga);
s = skiptowhite(p);
kp->from = vim_strnsave(p, (int)(s - p));
kp->from = vim_strnsave(p, (size_t)(s - p));
p = skipwhite(s);
s = skiptowhite(p);
kp->to = vim_strnsave(p, (int)(s - p));
kp->to = vim_strnsave(p, (size_t)(s - p));
if ((STRLEN(kp->from) + STRLEN(kp->to) >= KMAP_LLEN)
|| (*kp->from == NUL)