[Bug 48027] New: cmd pipe | not triggering ReadFile EOF
https://bugs.winehq.org/show_bug.cgi?id=48027 Bug ID: 48027 Summary: cmd pipe | not triggering ReadFile EOF Product: Wine Version: 4.18 Hardware: x86 OS: Linux Status: NEW Severity: minor Priority: P2 Component: cmd Assignee: wine-bugs(a)winehq.org Reporter: dark.shadow4(a)web.de Distribution: --- Test program is find.exe as of wine commit ccec532879ec14b2e79da08288152a69221ec4d1. I implemented the program so it waits for ReadFile to return FALSE, that's when the input is supposed to be over: ###### BOOL success = ReadFile(handle, buffer, 4096, &buffer_max, NULL); if (!success) return FALSE; ###### Now that's not right anyways, but it exposes a slight difference in Wine cmd: 1) Following input hangs on Wine, but not on Windows: "echo test | find test" It works on Wine when using "winetricks -q cmd" 2) Following input hangs on both Windows and Wine: "find test < test.txt" Wine's implementation of the pipe | uses the redirect operator < internally. This leads to the pipe working differently on Wine, i.e. blocking ReadFile when it's not supposed to. I'm not aware of a real program being affected by that, just noting. -- 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.
https://bugs.winehq.org/show_bug.cgi?id=48027 Fabian Maurer <dark.shadow4(a)web.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |source, testcase -- 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.
https://bugs.winehq.org/show_bug.cgi?id=48027 --- Comment #1 from Fabian Maurer <dark.shadow4(a)web.de> --- Created attachment 75937 --> https://bugs.winehq.org/attachment.cgi?id=75937 Compiled test program Use like "echo test | find2 test" -- 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.
http://bugs.winehq.org/show_bug.cgi?id=48027 Eric Pouech <eric.pouech(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |eric.pouech(a)gmail.com --- Comment #2 from Eric Pouech <eric.pouech(a)gmail.com> --- should be fixed by d28db44319d3558bcfe13b7da0c626b1ff9dd58a would you mind testing if it's really the case? -- 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.
http://bugs.winehq.org/show_bug.cgi?id=48027 --- Comment #3 from Fabian Maurer <dark.shadow4(a)web.de> --- I did a bisect, and it got fixed by commit 486f33ee64121d0331fb3e943791ec42bd98ef51 Author: Eric Pouech <epouech(a)codeweavers.com> Date: Mon Sep 1 09:14:04 2025 +0200 cmd: Run single commands in pipe in external cmd instance. Note: all builtin commands in LHS or RHS of a pipe shall be run in a separate cmd instance (to provide concurrency between RHS and LHS). -- 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.
http://bugs.winehq.org/show_bug.cgi?id=48027 Eric Pouech <eric.pouech(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED Fixed by SHA1| |d28db44319d3558bcfe13b7da0c | |626b1ff9dd58a --- Comment #4 from Eric Pouech <eric.pouech(a)gmail.com> --- thanks for (re)testing, good news it's solved actually, I'll use d28db44319d3558bcfe13b7da0c626b1ff9dd58a as the closing commit for this ticket as: - it refers to this very bugzilla entry - all commits between 486f33ee64121d0331fb3e943791ec42bd98ef51 and d28db44319d3558bcfe13b7da0c626b1ff9dd58a are needed to cover other forms of pipe commands -- 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.
http://bugs.winehq.org/show_bug.cgi?id=48027 Alexandre Julliard <julliard(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #5 from Alexandre Julliard <julliard(a)winehq.org> --- Closing bugs fixed in 10.18. -- 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.
participants (1)
-
WineHQ Bugzilla