TS-2595 DNS lookup failed with multiple search domains

Expand multiple search domains by appending each to original host name rather
than keep appending one after the other.
TS-2595 Skip domain expansion if original name ends with dot.
Added TS-2595 to CHANGES.

This closes #52
TS-2595 Minor cleanup on strlcpy returns