Modify retry handling in Socket::read

- Retry the read 10* times if the initial read sets errno to either
EAGAIN or EINTR
- Throw an exception if n is 0 or less than 0 and errno is different or
all retries have happened

* Should this be a constant?