Handle EINTR in recv/send/read/write syscalls
Handle EINTR in recv/send/read/write syscalls

This fixes a bug where, if recv() returned EINTR, we would mistakenly
think that the client had closed the socket rather than sent a request.
This patch makes it retry interrupted reads.

Tested using ApacheBench - without this patch, it would occasionally
get a couple errors, but now it passes without. Before fixing the bug,
I changed it to perror(errno) on a failed read, and saw that the number
of errors reported by ApacheBench lined up with the number of EINTRs.

Change-Id: I05fc06ad114aa204ccf001d6af3936e231e25ba0
Reviewed-on: http://gerrit.ent.cloudera.com:8080/1205
Reviewed-by: Colin McCabe <3142ce8a0bdba4a38073365893e6b74f72d9c512@cloudera.com>
Reviewed-by: Todd Lipcon <2c763d726a8c2f6afda9be7e0e56a2caa6bb5e6b@cloudera.com>
Tested-by: Todd Lipcon <2c763d726a8c2f6afda9be7e0e56a2caa6bb5e6b@cloudera.com>

danburkert/squeasel,brockn/squeasel,brockn/squeasel,danburkert/squeasel,danburkert/squeasel,danburkert/squeasel,danburkert/squeasel,brockn/squeasel,brockn/squeasel,danburkert/squeasel,brockn/squeasel,brockn/squeasel