diff --git a/common/ipprefix.cpp b/common/ipprefix.cpp index 6fb466101..7d8a3fe7e 100644 --- a/common/ipprefix.cpp +++ b/common/ipprefix.cpp @@ -61,7 +61,7 @@ IpPrefix::IpPrefix(const ip_addr_t &ip, int mask) : m_ip(ip), m_mask(mask) } } -bool IpPrefix::isValid() +bool IpPrefix::isValid() const { if (m_mask < 0) return false; diff --git a/common/ipprefix.h b/common/ipprefix.h index 6a348eb41..5ab7d3936 100644 --- a/common/ipprefix.h +++ b/common/ipprefix.h @@ -202,7 +202,7 @@ class IpPrefix std::string to_string() const; private: - bool isValid(); + bool isValid() const; IpAddress m_ip; int m_mask;