From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 62024 invoked by alias); 4 Oct 2017 03:39:53 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 62002 invoked by uid 89); 4 Oct 2017 03:39:52 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.1 required=5.0 tests=AWL,BAYES_40,FROM_STARTS_WITH_NUMS,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy=cyg, PTY, pty, simple.c X-HELO: smtp-out-so.shaw.ca Received: from smtp-out-so.shaw.ca (HELO smtp-out-so.shaw.ca) (64.59.136.137) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 04 Oct 2017 03:39:50 +0000 Received: from kylheku.com ([70.79.163.252]) by shaw.ca with SMTP id zaXCdMOAi8LPZzaXDdxGKs; Tue, 03 Oct 2017 21:39:48 -0600 X-Authority-Analysis: v=2.2 cv=e552ceh/ c=1 sm=1 tr=0 a=95A0EdhkF1LMGt25d7h1IQ==:117 a=95A0EdhkF1LMGt25d7h1IQ==:17 a=IkcTkHD0fZMA:10 a=SMorJkV_YP8A:10 a=02M-m0pO-4AA:10 a=vYxZw9q9pxtJsLTO4vEA:9 a=QEXdDO2ut3YA:10 Received: from www-data by kylheku.com with local (Exim 4.72) (envelope-from <920-082-4242@kylheku.com>) id 1dzaXC-0005Q0-M3 for cygwin@cygwin.com; Tue, 03 Oct 2017 20:39:46 -0700 To: cygwin@cygwin.com Subject: Re: bash pipe race condition X-PHP-Originating-Script: 501:rcmail.php MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Date: Wed, 04 Oct 2017 03:39:00 -0000 From: Kaz Kylheku <920-082-4242@kylheku.com> In-Reply-To: <33e9d184-03b1-5fa5-4c1a-0cca19571a3a@gmail.com> References: <33e9d184-03b1-5fa5-4c1a-0cca19571a3a@gmail.com> Message-ID: <3b4549f8494b5b4062e90eecc1dfc356@mail.kylheku.com> X-Sender: 920-082-4242@kylheku.com User-Agent: Roundcube Webmail/0.9.2 X-CMAE-Envelope: MS4wfONlhoNmonojPofZUvQCXndo66BT0K5fejnlNCp+tuIz6Tmv2ET+Py9ETOxXbAF7BcwOHFpRlPAnoajZP8iMnwpDzFJISKsDxG7/WdziIWEl63xaMXuo vMuge5m+YgI0Wqcmn6PIZh2Bt2KfyKoG9YxkZ2za0QmEBbddMb9hDjyR X-IsSubscribed: yes X-SW-Source: 2017-10/txt/msg00034.txt.bz2 On 03.10.2017 05:56, cyg Simple wrote: > On 10/2/2017 9:06 PM, Matthew McGIllis wrote: >> If I use the same code from bash I get: >> >> $ ./input.exe | ./simple.exe >> line1 >> <—— Hangs indefinitely until you kill it or ctrl-c >> >> Some how if input has a delay between its line output then things will >> get hung, if you remove the sleep from the input things work, add the >> sleep in it fails. >> >> >> input.exe is generate from input.vb using: vbc input.vb [ ... ] > > It is a known issue of the PTY emulation between a Cygwin runtime and a > Windows runtime enabled app. It just cannot be fixed. You're even > lucky that it works in the Windows command shell. Lucky? Are VB console apps known to have unreliable piping when used from the Windows command processor? > Either convert > simple.vb to simple.c and use Cygwin's gcc to build it or create a > Windows runtime version of input.exe. Isn't that what "input.exe is generate[d] from input.vb using: vbc input.vb" is referring to? -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple