From: Amos Jeffries Date: Tue, 24 Jun 2008 11:13:03 +0000 (+1200) Subject: Bug 2383: part 1: Typo in v6 special-case if-def X-Git-Tag: SQUID_3_1_0_1~49^2~193 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9b1f7ee8c8aea768c04630c02212f7da7f3987d0;p=thirdparty%2Fsquid.git Bug 2383: part 1: Typo in v6 special-case if-def Typo in IPV6_SPECIAL_V4MAPPING / IPV6_SPECIAL_MAPPED caused the #if to never be compiled. --- diff --git a/configure.in b/configure.in index a550cb1069..3eb077c147 100755 --- a/configure.in +++ b/configure.in @@ -1889,7 +1889,7 @@ AC_ARG_ENABLE(ipv6, [ AC_DEFINE(USE_IPV6,0,[0 == Disable support for IPv6]) AC_DEFINE(IPV6_SPECIAL_SPLITSTACK,0,[0 == Disable support for Split-Stack IPv6 Implementations]) AC_DEFINE(IPV6_SPECIAL_LOCALHOST,0,[0 == Keep IPv4 and IPv6 Localhosts seperate.]) - AC_DEFINE(IPV6_SPECIAL_V4MAPPING,0,[0 == Leave all v4-mapping to OS Implementation]) + AC_DEFINE(IPV6_SPECIAL_V4MAPPED,0,[0 == Leave all v4-mapping to OS Implementation]) AC_MSG_RESULT(no) ]) ) @@ -1897,7 +1897,7 @@ AC_ARG_ENABLE(ipv6, [ AC_DEFINE(USE_IPV6,0,[Disable support for IPv6]) AC_DEFINE(IPV6_SPECIAL_SPLITSTACK,0,[ 0 == Disable support for Split-Stack IPv6 Implementations]) AC_DEFINE(IPV6_SPECIAL_LOCALHOST,0,[ 0 == Keep IPv4 and IPv6 Localhosts seperate.]) - AC_DEFINE(IPV6_SPECIAL_V4MAPPING,0,[ 0 == Leave v4-mapping to OS Implementation]) + AC_DEFINE(IPV6_SPECIAL_V4MAPPED,0,[ 0 == Leave v4-mapping to OS Implementation]) AC_MSG_RESULT(no) ]) if test $ac_cv_enable_ipv6 ; then @@ -1910,11 +1910,12 @@ AC_ARG_WITH(ipv6-split-stack, ) dnl Check for IPv6 Windows Vista option +dnl Also useful for other OS AC_MSG_CHECKING([for IPv6 v4-mapping requirement]) AC_ARG_WITH(ipv4-mapped, [ --with-ipv4-mapped Hybrid-Stack OS require Squid to do any v4-mapping (Requires IPv6 Support)], - [AC_DEFINE(IPV6_SPECIAL_V4MAPPING, 1, [ 1 == Perform v4-mapping internally]) AC_MSG_RESULT(yes)], - [AC_DEFINE(IPV6_SPECIAL_V4MAPPING, 0, [ 0 == Leave all v4-mapping to the OS]) AC_MSG_RESULT(no)] + [AC_DEFINE(IPV6_SPECIAL_V4MAPPED, 1, [ 1 == Perform v4-mapping through v6 sockets]) AC_MSG_RESULT(yes)], + [AC_DEFINE(IPV6_SPECIAL_V4MAPPED, 0, [ 0 == Leave all v4-mapping to the OS default]) AC_MSG_RESULT(no)] ) dnl Check for IPv6-pure option diff --git a/src/comm.cc b/src/comm.cc index 9d227a6270..6f07ef0882 100644 --- a/src/comm.cc +++ b/src/comm.cc @@ -709,9 +709,10 @@ comm_openex(int sock_type, #endif -#if IPV6_SPECIAL_V4MAPPED && defined(_SQUID_MSWIN_) +#if IPV6_SPECIAL_V4MAPPED /* Windows Vista supports Dual-Sockets. BUT defaults them to V6ONLY. Turn it OFF. */ + /* Other OS may have this administratively disabled for general use. Same deal. */ if( addr.IsIPv6() ) comm_set_v6only(new_socket, 0);