X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org MIME-Version: 1.0 In-Reply-To: References: Date: Tue, 28 Jul 2009 13:27:15 +0200 Message-ID: Subject: Re: 1.7.0: read() blocking with VMIN = VTIME = 0 From: =?ISO-8859-1?Q?daniel_=E5kerud?= To: cygwin AT cygwin DOT com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: 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 On Tue, Jul 28, 2009 at 1:00 PM, daniel =E5kerud w= rote: > With my example program below the read() is blocking even though > canonical input is set and VMIN =3D VTIME =3D 0. I mean non-canonical here. *ups* > It is supposed to act in a non-blocking way. > And this is from the libc documentation: http://www.gnu.org/s/libc/manual/html_node/Noncanonical-Input.html#Noncanon= ical-Input 17.4.10 Noncanonical Input ... Both MIN and TIME are zero. In this case, read always returns immediately with as many characters as are available in the queue, up to the number requested. If no input is immediately available, read returns a value of zero. BR/Daniel -- 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