From 6f011f6e32ce4ac5d3dfb7aaa2c85f71711fd817 Mon Sep 17 00:00:00 2001 From: Maxim Mamontov Date: Sun, 13 Nov 2011 22:44:06 +0200 Subject: [PATCH] Some code reordering --- include/stg/user_ips.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/include/stg/user_ips.h b/include/stg/user_ips.h index 17bb59be..8fada63b 100644 --- a/include/stg/user_ips.h +++ b/include/stg/user_ips.h @@ -134,6 +134,14 @@ return ips.size(); } //----------------------------------------------------------------------------- inline +uint32_t USER_IPS::CalcMask(unsigned int msk) const +{ +if (msk > 32) + return 0; +return htonl(0xFFffFFff << (32 - msk)); +} +//----------------------------------------------------------------------------- +inline bool USER_IPS::IsIPInIPS(uint32_t ip) const { if (ips.empty()) @@ -163,14 +171,6 @@ return false; } //----------------------------------------------------------------------------- inline -uint32_t USER_IPS::CalcMask(unsigned int msk) const -{ -if (msk > 32) - return 0; -return htonl(0xFFffFFff << (32 - msk)); -} -//----------------------------------------------------------------------------- -inline void USER_IPS::Add(const IP_MASK &im) { ips.push_back(im); -- 2.44.2