Ed Schouten 6b1b791da6 Fix faulty error code handling in read(2) on TTYs.
When performing a non-blocking read(2), on a TTY while no data is
available, we should return EAGAIN. But if there's a modem disconnect,
we should return 0. Right now we only return 0 when doing a blocking
read, which is wrong.

MFC after:	1 month
2012-10-03 13:51:03 +00:00
..
2012-05-31 19:32:37 +00:00
2012-08-16 13:01:56 +00:00
2012-08-17 02:47:16 +00:00
2012-08-28 19:30:29 +00:00
2011-04-13 11:28:46 +00:00
2012-08-22 20:01:57 +00:00
2010-11-25 20:05:11 +00:00
2012-03-28 20:58:30 +00:00
2012-08-11 23:48:39 +00:00
2011-07-10 00:53:04 +00:00
2012-06-25 05:41:16 +00:00
2012-09-04 23:16:55 +00:00
2012-02-01 14:34:52 +00:00
2012-01-26 16:35:09 +00:00
2012-06-11 18:47:26 +00:00
2012-09-14 21:28:56 +00:00
2012-08-08 00:20:30 +00:00
2012-08-17 02:47:16 +00:00
2012-01-02 12:12:10 +00:00
2012-08-15 22:12:01 +00:00