mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
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:
@@ -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
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user