net: Respect the 'readable' flag on sockets

Previously, we were only destroying sockets on end if their readable
side had already been ended.  This causes a problem for non-readable
streams, since we don't expect to ever see an 'end' event from those.

Treat the lack of a 'readable' flag the same as if it was an ended
readable stream.

Fix #4751