summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2012-10-03 17:12:47 +0200
committerBram Moolenaar <Bram@vim.org>2012-10-03 17:12:47 +0200
commitec3cfeb19988dbeb4cfb27e735f3905149f79169 (patch)
tree3a8839fb682d9d5f7b89104169412c4726a34116
parent1e91f2606b2380e6e443e7389f7648d86fb8c654 (diff)
downloadvim-git-ec3cfeb19988dbeb4cfb27e735f3905149f79169.tar.gz
updated for version 7.3.675v7.3.675
Problem: Using uninitialized memory with very long file name. Solution: Put NUL after text when it is truncated. (ZyX)
-rw-r--r--src/buffer.c2
-rw-r--r--src/version.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/src/buffer.c b/src/buffer.c
index 0a2ce8ec9..599852321 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -3058,7 +3058,7 @@ fileinfo(fullname, shorthelp, dont_truncate)
*p++ = '"';
if (buf_spname(curbuf) != NULL)
- STRCPY(p, buf_spname(curbuf));
+ vim_strncpy(p, buf_spname(curbuf), IOSIZE - (p - buffer) - 1);
else
{
if (!fullname && curbuf->b_fname != NULL)
diff --git a/src/version.c b/src/version.c
index fff0079c2..1798f053c 100644
--- a/src/version.c
+++ b/src/version.c
@@ -720,6 +720,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 675,
+/**/
674,
/**/
673,