1
0
mirror of https://gitlab.xiph.org/xiph/icecast-common.git synced 2024-11-03 04:17:20 -05:00

build fix for older setups with IPv6

svn path=/icecast/trunk/net/; revision=14545
This commit is contained in:
Karl Heyes 2008-02-28 02:16:23 +00:00
parent 81ca1569fa
commit ce28de7894

View File

@ -699,7 +699,9 @@ sock_t sock_get_server_socket (int port, const char *sinterface)
setsockopt (sock, SOL_SOCKET, SO_REUSEADDR, (const void *)&on, sizeof(on)); setsockopt (sock, SOL_SOCKET, SO_REUSEADDR, (const void *)&on, sizeof(on));
on = 0; on = 0;
#ifdef IPV6_V6ONLY
setsockopt (sock, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof on); setsockopt (sock, IPPROTO_IPV6, IPV6_V6ONLY, &on, sizeof on);
#endif
if (bind (sock, ai->ai_addr, ai->ai_addrlen) < 0) if (bind (sock, ai->ai_addr, ai->ai_addrlen) < 0)
{ {