Normalize sockaddr on BSD and Darwin.

Fix bug involving comparing sockaddr structs. Discussion on #216.