Konstantin Belousov
39845728a1
Fix spurious ENOTCONN from closed unix domain socket other' side.
...
Sometimes, when doing read(2) over unix domain socket, for which the
other side socket was closed, read(2) returns -1/ENOTCONN instead of
EOF AKA zero-size read. This is because soreceive_generic() does not
lock socket when testing the so_state SS_ISCONNECTED|SS_ISCONNECTING
flags. It could end up that we do not observe so->so_rcv.sb_state bit
SBS_CANTRCVMORE, and then miss SS_ flags.
Change the test to check that the socket was never connected before
returning ENOTCONN, by adding all state bits for connected.
Reported and tested by: pho
In collaboration with: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D24819
2020-05-14 17:54:08 +00:00
..
2020-02-26 16:22:28 +00:00
2020-04-12 21:23:19 +00:00
2019-10-29 17:28:25 +00:00
2018-07-03 02:50:07 +00:00
2020-04-15 20:21:30 +00:00
2020-02-26 14:26:36 +00:00
2020-04-16 21:53:17 +00:00
2018-11-29 21:00:56 +00:00
2020-01-30 20:05:05 +00:00
2020-04-24 01:30:33 +00:00
2020-02-26 14:26:36 +00:00
2020-01-30 20:05:05 +00:00
2020-04-01 04:51:39 +00:00
2018-09-06 02:10:59 +00:00
2020-01-30 20:05:05 +00:00
2020-02-26 14:26:36 +00:00
2018-11-26 20:56:05 +00:00
2020-04-29 14:14:15 +00:00
2019-12-13 09:32:16 +00:00
2020-01-03 22:29:58 +00:00
2020-04-27 13:54:00 +00:00
2019-10-14 13:04:04 +00:00
2019-09-12 14:34:46 +00:00
2020-02-26 14:26:36 +00:00
2020-04-21 03:57:30 +00:00
2020-05-02 18:54:25 +00:00
2020-04-09 14:44:46 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-04-01 19:22:09 +00:00
2020-01-30 20:05:05 +00:00
2020-02-26 14:26:36 +00:00
2020-04-18 07:50:30 +00:00
2020-02-26 14:26:36 +00:00
2020-01-30 20:05:05 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-03-08 00:23:36 +00:00
2020-04-09 23:42:13 +00:00
2020-01-30 20:05:05 +00:00
2019-08-21 23:43:58 +00:00
2018-12-07 16:11:45 +00:00
2020-02-26 14:26:36 +00:00
2020-05-03 00:37:16 +00:00
2020-05-09 13:00:38 +00:00
2020-01-30 20:05:05 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2019-01-15 01:02:16 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-02-13 22:22:15 +00:00
2020-02-26 14:26:36 +00:00
2020-05-01 14:30:59 +00:00
2020-04-01 19:22:09 +00:00
2020-02-26 14:26:36 +00:00
2019-09-15 02:59:53 +00:00
2020-02-15 18:48:38 +00:00
2020-01-30 20:05:05 +00:00
2020-02-12 11:17:18 +00:00
2020-02-26 14:26:36 +00:00
2020-05-03 00:37:16 +00:00
2019-12-02 22:38:25 +00:00
2020-04-26 00:41:29 +00:00
2020-05-11 22:38:32 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-04-21 17:13:06 +00:00
2019-12-11 15:52:29 +00:00
2020-04-16 17:24:13 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-04-26 22:04:43 +00:00
2020-04-14 20:53:12 +00:00
2020-03-16 22:25:25 +00:00
2020-01-30 20:05:05 +00:00
2020-03-02 15:30:52 +00:00
2020-04-15 18:39:12 +00:00
2018-12-04 16:48:47 +00:00
2020-01-30 20:05:05 +00:00
2020-05-07 19:32:49 +00:00
2019-06-25 16:39:25 +00:00
2020-02-12 19:06:34 +00:00
2019-09-30 20:58:29 +00:00
2020-02-26 14:26:36 +00:00
2020-03-02 15:30:52 +00:00
2020-03-02 15:30:52 +00:00
2019-05-13 23:37:44 +00:00
2018-12-11 19:32:16 +00:00
2020-01-30 20:05:05 +00:00
2020-01-03 18:29:20 +00:00
2020-01-30 20:05:05 +00:00
2019-04-18 22:52:12 +00:00
2020-01-30 20:05:05 +00:00
2020-05-03 00:27:41 +00:00
2020-02-26 14:26:36 +00:00
2018-10-30 18:26:34 +00:00
2020-03-26 15:02:37 +00:00
2020-01-30 20:05:05 +00:00
2020-02-20 23:53:48 +00:00
2020-03-06 19:09:01 +00:00
2020-02-14 23:18:03 +00:00
2020-05-12 04:34:26 +00:00
2019-12-20 03:40:53 +00:00
2020-02-26 14:26:36 +00:00
2019-03-12 05:10:41 +00:00
2018-10-12 00:32:45 +00:00
2020-02-26 14:26:36 +00:00
2019-05-21 20:38:48 +00:00
2020-01-30 20:05:05 +00:00
2020-01-30 20:05:05 +00:00
2019-11-28 08:47:36 +00:00
2020-03-30 14:24:03 +00:00
2020-01-30 20:05:05 +00:00
2020-01-30 20:05:05 +00:00
2020-02-26 14:26:36 +00:00
2020-03-02 15:30:52 +00:00
2020-02-26 14:26:36 +00:00
2018-07-19 20:00:28 +00:00
2018-08-09 17:42:27 +00:00
2020-02-26 14:26:36 +00:00
2020-03-06 19:09:01 +00:00
2019-04-06 21:56:24 +00:00
2020-04-19 00:12:30 +00:00
2019-05-20 00:38:23 +00:00
2020-05-09 15:56:02 +00:00
2020-02-26 14:26:36 +00:00
2019-02-20 09:38:19 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-01-30 20:05:05 +00:00
2019-08-16 19:46:22 +00:00
2020-05-03 00:37:16 +00:00
2020-02-26 14:26:36 +00:00
2020-02-26 14:26:36 +00:00
2020-03-06 19:10:00 +00:00
2019-09-25 18:26:31 +00:00
2020-02-26 14:26:36 +00:00
2020-04-01 19:22:09 +00:00
2020-02-11 18:48:07 +00:00
2019-09-26 07:19:26 +00:00
2020-04-01 19:22:09 +00:00
2020-04-02 20:47:51 +00:00
2020-02-03 17:35:11 +00:00
2020-01-30 20:05:05 +00:00
2020-02-19 08:17:27 +00:00
2020-02-26 14:26:36 +00:00
2020-03-19 15:39:45 +00:00
2020-04-15 13:20:51 +00:00
2020-01-12 23:52:16 +00:00
2020-04-27 15:59:19 +00:00
2019-11-25 18:33:21 +00:00
2020-04-01 19:22:09 +00:00
2020-03-20 20:09:00 +00:00
2020-04-14 18:11:26 +00:00
2020-04-24 01:30:00 +00:00
2020-04-14 18:11:26 +00:00
2019-05-04 19:05:30 +00:00
2020-01-30 20:05:05 +00:00
2020-04-14 20:30:48 +00:00
2020-04-14 20:30:48 +00:00
2020-04-17 18:34:49 +00:00
2019-11-29 03:56:01 +00:00
2019-05-20 00:38:23 +00:00
2020-04-17 18:34:49 +00:00
2020-04-17 18:34:49 +00:00
2020-02-26 14:26:36 +00:00
2020-01-15 03:34:21 +00:00
2020-05-03 00:21:11 +00:00
2019-11-06 22:40:19 +00:00
2020-05-07 17:58:07 +00:00
2020-02-26 14:26:36 +00:00
2018-12-11 19:32:16 +00:00
2020-04-14 13:32:03 +00:00
2020-05-03 00:37:16 +00:00
2020-05-14 17:54:08 +00:00
2019-08-11 19:16:07 +00:00
2020-04-13 19:22:05 +00:00
2020-02-15 01:28:42 +00:00
2020-02-26 14:26:36 +00:00
2020-03-30 21:42:46 +00:00
2020-03-06 19:10:00 +00:00
2020-01-30 20:05:05 +00:00
2020-03-30 21:44:30 +00:00
2020-05-11 15:38:44 +00:00
2020-05-14 03:01:23 +00:00
2020-01-11 22:56:20 +00:00
2020-01-30 20:05:05 +00:00
2020-03-01 21:54:28 +00:00
2020-03-22 18:18:30 +00:00
2020-04-27 13:54:00 +00:00
2020-03-06 18:41:37 +00:00
2020-03-24 17:16:52 +00:00
2020-04-09 18:38:00 +00:00
2020-02-23 03:32:11 +00:00