jkunstle / rpms / vim

Forked from rpms/vim 3 years ago
Clone

Blame SOURCES/7.4.465

073263
To: vim_dev@googlegroups.com
073263
Subject: Patch 7.4.465
073263
Fcc: outbox
073263
From: Bram Moolenaar <Bram@moolenaar.net>
073263
Mime-Version: 1.0
073263
Content-Type: text/plain; charset=UTF-8
073263
Content-Transfer-Encoding: 8bit
073263
------------
073263
073263
Patch 7.4.465 (after 7.4.016)
073263
Problem:    Crash when expanding a very long string.
073263
Solution:   Use wsncpy() instead of wcscpy(). (Ken Takata)
073263
Files:	    src/os_win32.c
073263
073263
073263
*** ../vim-7.4.464/src/os_win32.c	2014-09-23 21:53:35.310849352 +0200
073263
--- src/os_win32.c	2014-10-06 18:37:27.437277105 +0200
073263
***************
073263
*** 2775,2783 ****
073263
  	if (p != NULL)
073263
  	{
073263
  	    char_u	*q;
073263
! 	    WCHAR	buf[_MAX_PATH + 2];
073263
  
073263
! 	    wcscpy(buf, p);
073263
  	    vim_free(p);
073263
  
073263
  	    if (fname_casew(buf, (len > 0) ? _MAX_PATH : 0) == OK)
073263
--- 2775,2784 ----
073263
  	if (p != NULL)
073263
  	{
073263
  	    char_u	*q;
073263
! 	    WCHAR	buf[_MAX_PATH + 1];
073263
  
073263
! 	    wcsncpy(buf, p, _MAX_PATH);
073263
! 	    buf[_MAX_PATH] = L'\0';
073263
  	    vim_free(p);
073263
  
073263
  	    if (fname_casew(buf, (len > 0) ? _MAX_PATH : 0) == OK)
073263
*** ../vim-7.4.464/src/version.c	2014-10-06 18:10:04.521273516 +0200
073263
--- src/version.c	2014-10-06 18:40:47.361277541 +0200
073263
***************
073263
*** 743,744 ****
073263
--- 743,746 ----
073263
  {   /* Add new patch number below this line */
073263
+ /**/
073263
+     465,
073263
  /**/
073263
073263
-- 
073263
Get a life?  What is the URL where it can be downloaded?
073263
073263
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
073263
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
073263
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
073263
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///