https://bugs.winehq.org/show_bug.cgi?id=46070
--- Comment #4 from Gabriel Ivăncescu gabrielopcode@gmail.com --- Sorry about that. The last time I sent a patch to fix it, it slept through the cracks and wasn't reviewed. I resent it, please see: https://www.winehq.org/pipermail/wine-devel/2020-September/174029.html
I believe Paul had an alternative fix but it was more complicated and had some issues with corner cases such as special fds like bash's pipe:[1234] and so on. I don't know if it fixed something extra though, I think nobody else commented on it.
If you want to take over with a better implementation/fix, please feel free to assign yourself or fix it properly. :-)