gvisor/pkg/sentry/socket/unix
Ian Gudger 12c7430a01 Fix recv blocking for connectionless Unix sockets.
Connectionless Unix sockets (DGRAM Unix sockets created with the socket system
call) inherently only have a read queue. They do not establish bidirectional
connections, instead, the connect system call only sets a default send
location. Writes give the data to the other endpoint which has its own read
queue.

To simplify the code, connectionless Unix sockets still get read and write
queues, but the write queue is a dummy and never waited on. The read queue is
the connectionless endpoint's queue. This change fixes a bug where the dummy
queue was incorrectly set as the read queue and the endpoint's queue was
incorrectly set as the write queue. This meant that read notifications went
to the dummy queue and were black holed.

PiperOrigin-RevId: 225921042
Change-Id: I8d9059def787a2c3c305185b92d05093fbd2be2a
2018-12-17 17:53:22 -08:00
..
transport Fix recv blocking for connectionless Unix sockets. 2018-12-17 17:53:22 -08:00
BUILD
device.go
io.go Convert Unix transport to syserr 2018-10-24 11:05:08 -07:00
unix.go Implement SO_SNDTIMEO 2018-12-14 16:15:06 -08:00