http://bugs.winehq.org/show_bug.cgi?id=18479
Summary: problem with writing to stdout under MSYS Product: Wine Version: 1.1.21 Platform: PC-x86-64 OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: -unknown AssignedTo: wine-bugs@winehq.org ReportedBy: jeffz@jeffz.name
install MSYS and MinGW, start MSYS using c:\MSYS\1.0\msys.bat
cd /c/mingw/bin ld --help
Nothing is printed, looking at a trace:
and an exception occurs in ld.exe, it looks like something has gone wrong with stdout:
Lots of: 0040:warn:msvcrt:msvcrt_fdtoh :fd (1) - no handle!
All the calls to puts printing the --help output etc return 0:
0040:Call msvcrt.puts(0048aafa "Link little-endian objects") ret=004070ab 0040:Ret msvcrt.puts() retval=00000000 ret=004070ab
And eventually the exception occurs:
0040:Call KERNEL32.MultiByteToWideChar(00000000,00000000,0048a305 " ",ffffffff,00000000,00000000) ret=7ed98632 0040:Ret KERNEL32.MultiByteToWideChar() retval=00000003 ret=7ed98632 0040:Call ntdll.RtlAllocateHeap(00110000,00000000,00000006) ret=7ed98658 0040:trace:seh:raise_exception code=c0000005 flags=0 addr=0x7bc4501d ip=7bc4501d tid=0040 ...
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #1 from Jeff Zaroyko jeffz@jeffz.name 2009-05-14 18:50:12 --- Created an attachment (id=21104) --> (http://bugs.winehq.org/attachment.cgi?id=21104) +relay,+msvcrt,+seh,+tid,+process
http://bugs.winehq.org/show_bug.cgi?id=18479
Jeff Zaroyko jeffz@jeffz.name changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download URL| |http://jeffz.name/wine/1847 | |9/
--- Comment #2 from Jeff Zaroyko jeffz@jeffz.name 2009-05-14 18:53:42 --- added convenient download URL for both MSYS and MinGW
http://bugs.winehq.org/show_bug.cgi?id=18479
Ivan Baldo ibaldo@adinet.com.uy changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |ibaldo@adinet.com.uy
http://bugs.winehq.org/show_bug.cgi?id=18479
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nerv@dawncrow.de
--- Comment #3 from André H. nerv@dawncrow.de 2009-05-24 11:09:05 --- duplicate of Bug 5541? can you try the patches from 5541?
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #4 from Jeff Zaroyko jeffz@jeffz.name 2009-05-24 20:24:45 --- (In reply to comment #3)
duplicate of Bug 5541? can you try the patches from 5541?
The patch doesn't help. ld --help still crashes.
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #5 from Ivan Baldo ibaldo@adinet.com.uy 2009-06-04 13:50:23 --- Found on 1.1.22 too. BTW running wine ld.exe --version works.
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #6 from Ivan Baldo ibaldo@adinet.com.uy 2009-06-11 21:31:31 --- Found on 1.1.23 too.
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #7 from Ivan Baldo ibaldo@adinet.com.uy 2009-06-23 19:15:21 --- Found on 1.1.24 too.
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #8 from André H. nerv@dawncrow.de 2009-08-14 10:39:07 --- Created an attachment (id=23065) --> (http://bugs.winehq.org/attachment.cgi?id=23065) msvcrt: dont overwrite the first 3 file descriptors
MSVCRT_fdend, which is is the highest file descriptor is possible set to zero in the init_io function. the first 3 file descriptors are stdin, stdout and stderr. so they are "overwritten" This patch fixes the problem and also some build problems i had in msys.
http://bugs.winehq.org/show_bug.cgi?id=18479
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |patch, source
--- Comment #9 from André H. nerv@dawncrow.de 2009-08-14 12:31:34 --- patch sent: http://www.winehq.org/pipermail/wine-patches/2009-August/077145.html
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #10 from André H. nerv@dawncrow.de 2009-08-21 12:51:02 --- patch with testcase: http://www.winehq.org/pipermail/wine-patches/2009-August/077473.html
http://bugs.winehq.org/show_bug.cgi?id=18479
Dan Kegel dank@kegel.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |dank@kegel.com
--- Comment #11 from Dan Kegel dank@kegel.com 2009-08-23 16:27:54 --- *** Bug 19812 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #12 from Dan Kegel dank@kegel.com 2009-08-29 16:36:55 --- Time to resend the patch? It works for me...
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #13 from Dan Kegel dank@kegel.com 2009-08-29 20:34:34 --- *** Bug 19785 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #14 from Dan Kegel dank@kegel.com 2009-08-29 21:47:02 --- *** Bug 19780 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #15 from André H. nerv@dawncrow.de 2009-09-03 13:32:23 --- (In reply to comment #12)
Time to resend the patch? It works for me...
AJ still wants a better testcase,but its tricky. so i got much deeper into it today and just need time to write the testcase.
http://bugs.winehq.org/show_bug.cgi?id=18479
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|wine-bugs@winehq.org |nerv@dawncrow.de
http://bugs.winehq.org/show_bug.cgi?id=18479
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Component|-unknown |msvcrt Resolution| |FIXED AssignedTo|nerv@dawncrow.de |wine-bugs@winehq.org
--- Comment #16 from André H. nerv@dawncrow.de 2009-09-10 10:42:41 --- After about 7 tries of me, AJ fixed it his self. :P
http://bugs.winehq.org/show_bug.cgi?id=18479
--- Comment #17 from Dan Kegel dank@kegel.com 2009-09-10 11:14:21 --- You showed him the way, though. Thanks!
http://bugs.winehq.org/show_bug.cgi?id=18479
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #18 from Alexandre Julliard julliard@winehq.org 2009-09-25 12:25:32 --- Closing bugs fixed in 1.1.30.
https://bugs.winehq.org/show_bug.cgi?id=18479
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |ded81aebc7ca9fe7a3362ec1b46 | |2dabad5e7986e