Patch 8.0.0852 (after 8.0.0850)
Problem: MS-Windows: possible crash when giving a message on startup.
Solution: Initialize length. (Yasuhiro Matsumoto, closes #1931)
Files: src/message.c
*** ../vim-8.0.0851/src/message.c 2017-08-03 17:37:44.547737719 +0200
--- src/message.c 2017-08-03 18:48:20.756745850 +0200
***************
*** 2639,2651 ****
# if defined(FEAT_MBYTE) && !defined(FEAT_GUI_MSWIN)
if (enc_codepage >= 0 && (int)GetConsoleCP() != enc_codepage)
{
! int len;
! WCHAR *widestr = (WCHAR *)enc_to_utf16(str, &len);
if (widestr != NULL)
{
! WideCharToMultiByte_alloc(GetConsoleCP(), 0, widestr, len,
! (LPSTR *)&ccp, &len, 0, 0);
vim_free(widestr);
s = str = ccp;
}
--- 2639,2652 ----
# if defined(FEAT_MBYTE) && !defined(FEAT_GUI_MSWIN)
if (enc_codepage >= 0 && (int)GetConsoleCP() != enc_codepage)
{
! int inlen = STRLEN(str);
! int outlen;
! WCHAR *widestr = (WCHAR *)enc_to_utf16(str, &inlen);
if (widestr != NULL)
{
! WideCharToMultiByte_alloc(GetConsoleCP(), 0, widestr, inlen,
! (LPSTR *)&ccp, &outlen, 0, 0);
vim_free(widestr);
s = str = ccp;
}
*** ../vim-8.0.0851/src/version.c 2017-08-03 17:53:59.296577109 +0200
--- src/version.c 2017-08-03 18:53:38.634428790 +0200
***************
*** 771,772 ****
--- 771,774 ----
{ /* Add new patch number below this line */
+ /**/
+ 852,
/**/
--
Seen on the back of a biker's vest: If you can read this, my wife fell off.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.