diff options
author | Bram Moolenaar <Bram@vim.org> | 2012-01-10 22:26:17 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2012-01-10 22:26:17 +0100 |
commit | 70b2a56d5a8fd54f3d0707fa77dea86a4bd8195f (patch) | |
tree | 2144b21b49d79de16665fb585daf1e9cf66e85c0 /src/misc2.c | |
parent | 1f5965b3c4d2b29e167a5dfecdf0ec59fe4c45c0 (diff) | |
download | vim-git-70b2a56d5a8fd54f3d0707fa77dea86a4bd8195f.tar.gz |
updated for version 7.3.400v7.3.400
Problem: Compiler warnings for shadowed variables.
Solution: Remove or rename the variables.
Diffstat (limited to 'src/misc2.c')
-rw-r--r-- | src/misc2.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/misc2.c b/src/misc2.c index 96c3a3638..22d1fb46b 100644 --- a/src/misc2.c +++ b/src/misc2.c @@ -1559,7 +1559,7 @@ strup_save(orig) if (enc_utf8) { int c, uc; - int nl; + int newl; char_u *s; c = utf_ptr2char(p); @@ -1568,21 +1568,21 @@ strup_save(orig) /* Reallocate string when byte count changes. This is rare, * thus it's OK to do another malloc()/free(). */ l = utf_ptr2len(p); - nl = utf_char2len(uc); - if (nl != l) + newl = utf_char2len(uc); + if (newl != l) { - s = alloc((unsigned)STRLEN(res) + 1 + nl - l); + s = alloc((unsigned)STRLEN(res) + 1 + newl - l); if (s == NULL) break; mch_memmove(s, res, p - res); - STRCPY(s + (p - res) + nl, p + l); + STRCPY(s + (p - res) + newl, p + l); p = s + (p - res); vim_free(res); res = s; } utf_char2bytes(uc, p); - p += nl; + p += newl; } else if (has_mbyte && (l = (*mb_ptr2len)(p)) > 1) p += l; /* skip multi-byte character */ |