folly: AsyncServerSocket::getAddress: prefer IPv6
authorLucian Grijincu <lucian@fb.com>
Tue, 23 Dec 2014 10:19:34 +0000 (02:19 -0800)
committerDave Watson <davejwatson@fb.com>
Mon, 29 Dec 2014 18:40:11 +0000 (10:40 -0800)
commitcc42e3ad3a3ef875f5353c06b9b4a99202ba445f
tree3e760d9fe5ee17f40a1b06346416568ac1877b35
parentdff24ff9ab40244a55122e1f420b169950b2d13a
folly: AsyncServerSocket::getAddress: prefer IPv6

Summary: Can't connect from ipv6-only cluster to ipv4/ipv6 service which uses different ports.

Test Plan:
```
./fastcopy_server --dir . &

# netstat -atnlp | grep LISTEN | grep fastc
tcp        0      0 0.0.0.0:65478               0.0.0.0:*                   LISTEN      9348/./fastcopy_ser
tcp        0      0 :::52793                    :::*                        LISTEN      9348/./fastcopy_ser
```

Reviewed By: philipp@fb.com, sdoroshenko@fb.com

Subscribers: ps, bmatheny, folly-diffs@

FB internal diff: D1752846

Tasks: 5868818

Signature: t1:1752846:1419043494:7cc0646882249f17258ade5ce7ae5619b13148a0
folly/io/async/AsyncServerSocket.cpp