| To: vim_dev@googlegroups.com |
| Subject: Patch 7.4.160 |
| Fcc: outbox |
| From: Bram Moolenaar <Bram@moolenaar.net> |
| Mime-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| |
| Patch 7.4.160 |
| Problem: Win32: Crash when executing external command. |
| Solution: Only close the handle when it was created. (Yasuhiro Matsumoto) |
| Files: src/os_win32.c |
| |
| |
| |
| |
| |
| *** 4627,4632 **** |
| --- 4627,4633 ---- |
| DWORD flags = CREATE_NEW_CONSOLE; |
| char_u *p; |
| |
| + ZeroMemory(&si, sizeof(si)); |
| si.cb = sizeof(si); |
| si.lpReserved = NULL; |
| si.lpDesktop = NULL; |
| |
| *** 4723,4731 **** |
| if (newcmd != cmdbase) |
| vim_free(newcmd); |
| |
| ! if (si.hStdInput != NULL) |
| { |
| ! /* Close the handle to \\.\NUL */ |
| CloseHandle(si.hStdInput); |
| } |
| /* Close the handles to the subprocess, so that it goes away */ |
| --- 4724,4732 ---- |
| if (newcmd != cmdbase) |
| vim_free(newcmd); |
| |
| ! if (si.dwFlags == STARTF_USESTDHANDLES && si.hStdInput != NULL) |
| { |
| ! /* Close the handle to \\.\NUL created above. */ |
| CloseHandle(si.hStdInput); |
| } |
| /* Close the handles to the subprocess, so that it goes away */ |
| |
| |
| |
| *** 740,741 **** |
| --- 740,743 ---- |
| { /* Add new patch number below this line */ |
| + /**/ |
| + 160, |
| /**/ |
| |
| -- |
| hundred-and-one symptoms of being an internet addict: |
| 209. Your house stinks because you haven't cleaned it in a week. |
| |
| /// Bram Moolenaar -- Bram@Moolenaar.net -- 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 /// |