[Bug 51813] python fatal error redirecting stdout to file

WineHQ Bugzilla wine-bugs at winehq.org
Tue Dec 7 13:22:06 CST 2021


https://bugs.winehq.org/show_bug.cgi?id=51813

Bernhard Übelacker <bernhardu at mailbox.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bernhardu at mailbox.org

--- Comment #2 from Bernhard Übelacker <bernhardu at mailbox.org> ---
Created attachment 71237
  --> https://bugs.winehq.org/attachment.cgi?id=71237
Workaround for redirection at linux side.

As far as I see does python query GetFileType for the handle from stdin which
returns in the redirected case FILE_TYPE_DISK.
Therefore it looks like python calls GetFileInformationByHandle
and expects this to succeed.

In the case of a redirection created by cmd in native or wine
this works as expected.
But GetFileInformationByHandle fails if the redirection is
done at linux side because fd->unix_name gets not set.

Attached patch should demonstrate the issue and possible workaround.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.


More information about the wine-bugs mailing list