Rename unix domain specific socket functions.
Group unix domain specific functions together in socket.c.
socket.c: refactor select wrappers