Add "Listen4" config option

"Listen6" and "Listen4" now do what the name implies and "Listen" listens on
both ipv4 and ipv6 (unless a bind host was set which forces something
different).

This also changes webadmin appropriately.

Thanks to DarthGandalf for the idea and the patch.


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1816 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2010-03-08 17:23:53 +00:00
parent aa9edc13b9
commit 6acaebf775
5 changed files with 85 additions and 26 deletions

View File

@@ -735,9 +735,20 @@ public:
#endif
#ifdef HAVE_IPV6
if (pListener->IsIPV6()) {
l["IsIPV6"] = "true";
switch (pListener->GetAddrType()) {
case ADDR_IPV4ONLY:
l["IsIPV4"] = "true";
break;
case ADDR_IPV6ONLY:
l["IsIPV6"] = "true";
break;
case ADDR_ALL:
l["IsIPV4"] = "true";
l["IsIPV6"] = "true";
break;
}
#else
l["IsIPV4"] = "true";
#endif
}