On Wed Feb 14 17:55:41 2024 +0000, Paul Gofman wrote:
Can you give some examples what do you mean with "exposed as pipe but
pipe's operation doesn't work"? Run Wine program with stderr piped somewhere through '|'. Or to a file created with mkfifo. That will be reported as pipe in GetFileInformationByHandle, but if an app (like some runtimes do) will then expect some pipe operations to work that will fail similarly to what happens with python vs files without name retrieval not working.
Yeah, it doesn't handle those (purposefully). Do you think we should
change `GetFileInformationByHandle` instead somehow? https://gitlab.winehq.org/wine/wine/-/merge_requests/1425 : I apparently thought so, but everything happened as Alexandre had foreseen in the comment there. Same or different runtimes expect then normal file operations to work. And IIRC reporting something weird like unknown or serial device doesn't universally work too I am not sure if we have any good option here of both keeping Unix fd integration and making this fully correct.
That's true for pipes, but in the case of the linked bug, it happens when it's redirected to actual files. Python expects it to work because it's redirected to files, so it shouldn't be a problem?
Maybe it doesn't cover all cases with pipes, but can you give a small (even if contrived) example where my patch actually introduces *wrong* behavior here so I can investigate it more?
I mean even if it doesn't fix all cases like this, it's still better than nothing…