* dtable.cc (dtable::init_std_file_from_handle): Fix comment to

document change in the Windows 7 workaround.
	* wincap.cc (wincapc::init): Don't set has_console_handle_problem
	to false on 32 bit systems.
This commit is contained in:
Corinna Vinschen 2009-08-08 20:24:54 +00:00
parent 75bf04114e
commit 7be107ce24
3 changed files with 18 additions and 18 deletions

View File

@ -1,3 +1,10 @@
2009-08-08 Corinna Vinschen <corinna@vinschen.de>
* dtable.cc (dtable::init_std_file_from_handle): Fix comment to
document change in the Windows 7 workaround.
* wincap.cc (wincapc::init): Don't set has_console_handle_problem
to false on 32 bit systems.
2009-08-06 Corinna Vinschen <corinna@vinschen.de> 2009-08-06 Corinna Vinschen <corinna@vinschen.de>
* net.cc (cygwin_getnameinfo): Force setting NI_NUMERICSERV only * net.cc (cygwin_getnameinfo): Force setting NI_NUMERICSERV only

View File

@ -360,26 +360,20 @@ dtable::init_std_file_from_handle (int fd, HANDLE handle)
else else
access |= GENERIC_WRITE; /* Should be rdwr for stderr but not sure that's access |= GENERIC_WRITE; /* Should be rdwr for stderr but not sure that's
possible for some versions of handles */ possible for some versions of handles */
/* FIXME: Workaround Windows 7 64 bit issue. If the parent process of /* FIXME: Workaround Windows 7 issue. If the parent process of
the process tree closes the original handles to the console window, the process tree closes the original handles to the console window,
strange problems occur when starting child processes later on if strange problems occur when starting child processes later on if
stdio redirection is used. How to reproduce: stdio redirection is used.
shell script foo: CV 2009-08-08: It looks like this problem has been fixed only
half-heartedly in RTM. Unfortunately the new implementation
exec 2>foo.log has still a problem which now also occurs on the 32 bit release
FOO=$( uname -n | cat ) of Windows 7. It's still not quite clear what happens but it's
echo $FOO easily reproducible. Just start X via the start menu entry.
This opens an xterm window with a shell. Exit from the shell,
start from cmd with `bash foo'. The result is that the cat process and you get a Windows error box reporting a crash in the
will be started but dies before Cygwin strace output can be generated Console Window Host application (conhost.exe) due to an access
and $FOO stays empty. The strace output shows that bash tries violation.
multiple times to start cat, but none of the invocations of cat will
ever show up in the strace output.
Remove the `exec 2>' or remove the cat call and the script will work.
Start bash interactively, then start the script manually, and the
script will work.
This needs further investigation but the workaround not to close This needs further investigation but the workaround not to close
the handles will have a marginal hit of three extra handles per the handles will have a marginal hit of three extra handles per

View File

@ -551,7 +551,6 @@ wincapc::init ()
{ {
((wincaps *)caps)->needs_count_in_si_lpres2 = false; ((wincaps *)caps)->needs_count_in_si_lpres2 = false;
((wincaps *)caps)->has_restricted_stack_args = false; ((wincaps *)caps)->has_restricted_stack_args = false;
((wincaps *)caps)->has_console_handle_problem = false;
} }
__small_sprintf (osnam, "NT-%d.%d", version.dwMajorVersion, __small_sprintf (osnam, "NT-%d.%d", version.dwMajorVersion,