delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/03/12/04:06:54

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
X-ASG-Debug-ID: 1584000357-061c4176ba42b20001-w5GHUG
X-Barracuda-Envelope-From: dickey AT his DOT com
X-Barracuda-RBL-Trusted-Forwarder: 216.194.196.20
X-Barracuda-RBL-IP: 18.222.154.13
X-Barracuda-Effective-Source-IP: zproxy102.his.com[18.222.154.13]
X-Barracuda-Apparent-Source-IP: 18.222.154.13
X-Virus-Scanned: amavisd-new at zproxy102.his.com
Date: Thu, 12 Mar 2020 04:05:56 -0400 (EDT)
From: Thomas Dickey <dickey AT his DOT com>
To: =?utf-8?B?w4VrZQ==?= Rehnman <ake DOT rehnman AT gmail DOT com>
Message-ID: <791909910.16332184.1584000356533.JavaMail.zimbra@his.com>
In-Reply-To: <9e4c6428-59de-df07-9e33-44ba95d5497f@gmail.com>
References: <mailman DOT 1473 DOT 1583981776 DOT 15804 DOT cygwin AT cygwin DOT com>
Subject: Re: Setting termios VMIN > 0 and VTIME > 0 on non blocking file
MIME-Version: 1.0
X-ASG-Orig-Subj: Re: Setting termios VMIN > 0 and VTIME > 0 on non blocking
file
X-Originating-IP: [71.246.219.82]
X-Mailer: Zimbra 8.8.15_GA_3888 (ZimbraWebClient - FF73 (Mac)/8.8.15_GA_3869)
Thread-Topic: Setting termios VMIN > 0 and VTIME > 0 on non blocking file
Thread-Index: u/WRkCZ6W6BzogRDDkDFtmn9TPjCCw==
X-Barracuda-Connect: smtp-nf-202.his.com[216.194.196.20]
X-Barracuda-Start-Time: 1584000357
X-Barracuda-URL: https://spam.his.com:443/cgi-mod/mark.cgi
X-Virus-Scanned: by bsmtpd at his.com
X-Barracuda-Scan-Msg-Size: 1084
X-Barracuda-BRTS-Status: 1
X-Barracuda-Spam-Score: 0.00
X-Barracuda-Spam-Status: No, SCORE=0.00 using global scores of TAG_LEVEL=1000.0
QUARANTINE_LEVEL=1000.0 KILL_LEVEL=6.0 tests=
X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.80618
Rule breakdown below
pts rule name description
---- ---------------------- --------------------------------------------------
X-Spam-Status: No, score=-7.6 required=5.0 tests=BAYES_00, GIT_PATCH_2,
RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,
SPF_PASS autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: Cygwin mailing list <cygwin.cygwin.com>
List-Unsubscribe: <http://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <http://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
Cc: cygwin <cygwin AT cygwin DOT com>
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>
X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 02C86ThA025899

----- Original Message -----
| From: "Ã…ke Rehnman" <ake DOT rehnman AT gmail DOT com>
| To: "cygwin" <cygwin AT cygwin DOT com>
| Sent: Wednesday, March 11, 2020 4:48:05 PM
| Subject: Setting termios VMIN > 0 and VTIME > 0 on non blocking file

| Hello all,
| 
| opening a file (serial port) with O_NONBLOCK and subsequently setting
| termios VMIN and VTIME > 0 makes read() never ever return any data
| (returns EAGAIN indefinitely).
| 
| Don't ask my why one would want to do something like this but apparently
| the "screen" program think this is a good way of doing things...
| 
| Nevertheless not returning any data ever seems wrong.
| 
| Any insight on how it is supposed to work is welcome.

If not "correct", it's certainly inconsistent with all other systems.
I noticed it recently:

https://invisible-island.net/ncurses/tack/CHANGES.html#t20200220

https://github.com/cygwinports/tack/issues/1

It's either recently-broken, or just coincidence :-)

-- 
Thomas E. Dickey <dickey AT invisible-island DOT net>
http://invisible-island.net
ftp://ftp.invisible-island.net
--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019