* fhandler_console.cc (create_invisible_console_workaround): Fix

size of cmd to take spaces into account.
This commit is contained in:
Corinna Vinschen
2009-08-10 08:54:51 +00:00
parent 4f2e34d821
commit 264ae244af
2 changed files with 6 additions and 1 deletions

View File

@ -2008,7 +2008,7 @@ fhandler_console::create_invisible_console_workaround ()
STARTUPINFOW si = {};
PROCESS_INFORMATION pi;
size_t len = helper.get_wide_win32_path_len ();
WCHAR cmd[len + (2 * strlen ("0xffffffff")) + 1];
WCHAR cmd[len + (2 * strlen ("0xffffffff")) + 2 /* spaces */ + 1];
WCHAR title[] = L"invisible cygwin console";
helper.get_wide_win32_path (cmd);