diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-07-10 13:52:13 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-07-10 13:52:13 +0200 |
commit | 0bc380a96b87ee02b01a7d4677ad4d973563a84e (patch) | |
tree | d459d5f3edebe4ae3a7b144dadda984bfaa3e5f9 /src/normal.c | |
parent | d04b7507fde8bb7e3103ce53f2156c798b5e5245 (diff) | |
download | vim-git-0bc380a96b87ee02b01a7d4677ad4d973563a84e.tar.gz |
Fixed ":s" message. Docs updates.
Diffstat (limited to 'src/normal.c')
-rw-r--r-- | src/normal.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/normal.c b/src/normal.c index 14578834f..efcdb7992 100644 --- a/src/normal.c +++ b/src/normal.c @@ -5410,6 +5410,7 @@ nv_ident(cap) { char_u *ptr = NULL; char_u *buf; + char_u *newbuf; char_u *p; char_u *kp; /* value of 'keywordprg' */ int kp_help; /* 'keywordprg' is ":help" */ @@ -5562,13 +5563,14 @@ nv_ident(cap) vim_free(buf); return; } - buf = (char_u *)vim_realloc(buf, STRLEN(buf) + STRLEN(p) + 1); - if (buf == NULL) + newbuf = (char_u *)vim_realloc(buf, STRLEN(buf) + STRLEN(p) + 1); + if (newbuf == NULL) { vim_free(buf); vim_free(p); return; } + buf = newbuf; STRCAT(buf, p); vim_free(p); } |