<div dir="ltr">Hello,<div><br></div><div>I've been working through the 'cmd' component bugs and am looking into bug#37780 (which relates to an old wontfix bug#34730) and wanted to get confirmation from an expert. This bug complains that if you manually create a file with a .exe extension, mark it executable (from Unix permissions perspective) and contains shell script (#!/bin/bash etc) then cmd.exe can launch the process but doesn't wait for it to complete.  This is true and reproducible - see 34730 for extensive details including AJ saying that is an ok to launch unix scripts (comment #23)</div><div><br></div><div>Debugging this, it would appear our cmd code decides not to wait (which is trivial to fix), but even if we try to wait we cannot - It would appear that CreateProcess for such a '.exe' file works, BUT it does not return a valid handle which can be waited on. I cannot say I am massively surprised by this but without a valid waitable handle, we obviously cannot give the user what they want</div><div><br></div><div>Questions/thoughts</div><div>- Is it desirable to do anything about this or just close wontfix, ie launching unix shell is asynchronous?</div><div>- Is it even possible to return a valid handle from CreateProcess that we can WaitForSingleObject on to know when the unix process completes?</div><div><br></div><div>Thanks,</div><div>Jason</div><div><br></div><div><br></div></div>