Socket code improvements (error checking)
Socket code improvements (error checking)

FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup,FriendSoftwareLabs/friendup