X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-0.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org To: cygwin AT cygwin DOT com From: Achim Gratz Subject: Re: [Bug] Named Pipes (FIFO) / Bash Date: Wed, 10 Aug 2011 17:05:47 +0200 Lines: 25 Message-ID: <871uwt1f3o.fsf@Rainer.invalid> References: <87ipxgirl7 DOT fsf AT Rainer DOT invalid> Mime-Version: 1.0 Content-Type: text/plain User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Achim Gratz writes: > In other words, opening the pipe is non-blocking, even though no > listener is present. Listing /proc/self/fd lists fd 6 as opened to FIFO > /tmp/pipe, but any output to it blocks indefinitely. I believe that the > FIFO has in fact never been opened as far as the system is concerned. > The output then blocks on the apparently not-open FIFO (I should be > getting a SIGPIPE instead when trying to write into a pipe that has no > listener). I've checked again with the latest snapshot (2011-08-03), after doing a full update and rebaseall. While the FIFO implementation still does not conform to POSIX w.r.t. blocking, it now gives consistent results again (as it was in Cygwin 1.5), does not block listeners indefinitely anymore and kills a listener with SIGPIPE when the producer goes away. So if the scripts are written to assume that behaviour, you can again use FIFO to synchronize processes. Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Wavetables for the Terratec KOMPLEXER: http://Synth.Stromeko.net/Downloads.html#KomplexerWaves -- 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