THRIFT-5129: Fix swift TSocketTransport on Mac
Client: Swift
Patch: Eric Chen
This closes #2149
diff --git a/lib/swift/Sources/TSocketTransport.swift b/lib/swift/Sources/TSocketTransport.swift
index 57f6215..640612b 100644
--- a/lib/swift/Sources/TSocketTransport.swift
+++ b/lib/swift/Sources/TSocketTransport.swift
@@ -159,7 +159,7 @@
var addr = sockaddr_in(sin_len: UInt8(MemoryLayout<sockaddr_in>.size),
sin_family: sa_family_t(AF_INET),
sin_port: in_port_t(htons(UInt16(port))),
- sin_addr: in_addr(s_addr: in_addr_t(0)),
+ sin_addr: hostAddr,
sin_zero: (0, 0, 0, 0, 0, 0, 0, 0))
#endif