]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/cidr.cpp
Introduce "X" snomask for remote *:line messages [patch by jackmcbarn]
[user/henk/code/inspircd.git] / src / cidr.cpp
index 669ccd8d27f6df9fd685c1b29728f407c4ea2460..d38056b0298195e46679637c9b51b2f05b0a8fb1 100644 (file)
@@ -2,8 +2,8 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
- * See: http://www.inspircd.org/wiki/index.php/Credits
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
+ * See: http://wiki.inspircd.org/Credits
  *
  * This program is free but copyrighted software; see
  *            the file COPYING for details.
@@ -121,7 +121,6 @@ bool irc::sockets::MatchCIDR(const std::string &address, const std::string &cidr
                return false;
        }
 
-#ifdef SUPPORT_IP6LINKS
        in6_addr address_in6;
        in6_addr mask_in6;
 
@@ -143,9 +142,7 @@ bool irc::sockets::MatchCIDR(const std::string &address, const std::string &cidr
                        return false;
                }
        }
-       else
-#endif
-       if (inet_pton(AF_INET, address_copy.c_str(), &address_in4) > 0)
+       else if (inet_pton(AF_INET, address_copy.c_str(), &address_in4) > 0)
        {
                if (inet_pton(AF_INET, cidr_copy.c_str(), &mask_in4) > 0)
                {