diff options
author | Pierre Ossman <ossman@cendio.se> | 2006-04-19 07:31:11 +0000 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2006-04-19 07:31:11 +0000 |
commit | 4bb58226189763b87abc5b5e0f297dd04f751d89 (patch) | |
tree | f2c103c493401ec0feb18f457606f84e4e96b110 /src/modules | |
parent | 494f60207404dc3d155047fab3e3cc1d4870f4f5 (diff) |
Reverse order of IPv6/IPv4 binding to handle systems without IPV6_V6ONLY.
System that always do IPV6_V6ONLY will now still bind to both sockets, just
in another order.
System that never do IPV6_V6ONLY will now fail to bind IPv4 instead of IPv6.
But since they force IPv6 sockets to accept IPv4 connections, everything is
peachy anyway.
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@756 fefdeb5f-60dc-0310-8127-8f9354f1896f
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/module-protocol-stub.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/modules/module-protocol-stub.c b/src/modules/module-protocol-stub.c index 2f022b99..0ffd81df 100644 --- a/src/modules/module-protocol-stub.c +++ b/src/modules/module-protocol-stub.c @@ -211,14 +211,14 @@ int pa__init(pa_core *c, pa_module*m) { listen_on = pa_modargs_get_value(ma, "listen", NULL); if (listen_on) { - s_ipv4 = pa_socket_server_new_ipv4_string(c->mainloop, listen_on, port, TCPWRAP_SERVICE); s_ipv6 = pa_socket_server_new_ipv6_string(c->mainloop, listen_on, port, TCPWRAP_SERVICE); + s_ipv4 = pa_socket_server_new_ipv4_string(c->mainloop, listen_on, port, TCPWRAP_SERVICE); } else if (loopback) { - s_ipv4 = pa_socket_server_new_ipv4_loopback(c->mainloop, port, TCPWRAP_SERVICE); s_ipv6 = pa_socket_server_new_ipv6_loopback(c->mainloop, port, TCPWRAP_SERVICE); + s_ipv4 = pa_socket_server_new_ipv4_loopback(c->mainloop, port, TCPWRAP_SERVICE); } else { - s_ipv4 = pa_socket_server_new_ipv4_any(c->mainloop, port, TCPWRAP_SERVICE); s_ipv6 = pa_socket_server_new_ipv6_any(c->mainloop, port, TCPWRAP_SERVICE); + s_ipv4 = pa_socket_server_new_ipv4_any(c->mainloop, port, TCPWRAP_SERVICE); } if (!s_ipv4 && !s_ipv6) |