From: Marcin Siodelski Date: Tue, 25 Sep 2012 12:58:47 +0000 (+0200) Subject: [1960] Moved static consts out of the TestControl class. X-Git-Tag: trac2351_base~40^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d98f7060780fc89f05c1610d3e88403969dfc819;p=thirdparty%2Fkea.git [1960] Moved static consts out of the TestControl class. Having static consts inside of the class causes linking errors on Mac/GCC. --- diff --git a/tests/tools/perfdhcp/test_control.h b/tests/tools/perfdhcp/test_control.h index e60add2344..1a29d093c9 100644 --- a/tests/tools/perfdhcp/test_control.h +++ b/tests/tools/perfdhcp/test_control.h @@ -33,6 +33,28 @@ namespace isc { namespace perfdhcp { +/// Default transaction id offset in the packet template. +static const size_t DHCPV4_TRANSID_OFFSET = 4; +/// Default offset of MAC's last octet in the packet template.. +static const size_t DHCPV4_RANDOMIZATION_OFFSET = 35; +/// Default elapsed time offset in the packet template. +static const size_t DHCPV4_ELAPSED_TIME_OFFSET = 8; +/// Default server id offset in the packet template. +static const size_t DHCPV4_SERVERID_OFFSET = 54; +/// Default requested ip offset in the packet template. +static const size_t DHCPV4_REQUESTED_IP_OFFSET = 240; +/// Default DHCPV6 transaction id offset in t the packet template. +static const size_t DHCPV6_TRANSID_OFFSET = 1; +/// Default DHCPV6 randomization offset (last octet of DUID) +/// in the packet template. +static const size_t DHCPV6_RANDOMIZATION_OFFSET = 21; +/// Default DHCPV6 elapsed time offset in the packet template. +static const size_t DHCPV6_ELAPSED_TIME_OFFSET = 84; +/// Default DHCPV6 server id offset in the packet template. +static const size_t DHCPV6_SERVERID_OFFSET = 22; +/// Default DHCPV6 IA_NA offset in the packet template. +static const size_t DHCPV6_IA_NA_OFFSET = 40; + /// \brief Test Control class. /// /// This singleton class is used to run the performance test with @@ -97,28 +119,6 @@ namespace perfdhcp { class TestControl : public boost::noncopyable { public: - /// Default transaction id offset in the packet template. - static const size_t DHCPV4_TRANSID_OFFSET = 4; - /// Default offset of MAC's last octet in the packet template.. - static const size_t DHCPV4_RANDOMIZATION_OFFSET = 35; - /// Default elapsed time offset in the packet template. - static const size_t DHCPV4_ELAPSED_TIME_OFFSET = 8; - /// Default server id offset in the packet template. - static const size_t DHCPV4_SERVERID_OFFSET = 54; - /// Default requested ip offset in the packet template. - static const size_t DHCPV4_REQUESTED_IP_OFFSET = 240; - /// Default DHCPV6 transaction id offset in t the packet template. - static const size_t DHCPV6_TRANSID_OFFSET = 1; - /// Default DHCPV6 randomization offset (last octet of DUID) - /// in the packet template. - static const size_t DHCPV6_RANDOMIZATION_OFFSET = 21; - /// Default DHCPV6 elapsed time offset in the packet template. - static const size_t DHCPV6_ELAPSED_TIME_OFFSET = 84; - /// Default DHCPV6 server id offset in the packet template. - static const size_t DHCPV6_SERVERID_OFFSET = 22; - /// Default DHCPV6 IA_NA offset in the packet template. - static const size_t DHCPV6_IA_NA_OFFSET = 40; - /// Statistics Manager for DHCPv4. typedef StatsMgr StatsMgr4; /// Pointer to Statistics Manager for DHCPv4;