From 0cf3dd3342f96110fd13354d329dc8d7862aa8ec Mon Sep 17 00:00:00 2001 From: Matias Fontanini Date: Sun, 24 Jan 2016 14:13:34 -0800 Subject: [PATCH] Move utils.h implementations to utils.cpp --- CMakeLists.txt | 1 + include/tins/dhcp.h | 2 +- include/tins/dhcpv6.h | 2 +- include/tins/icmpv6.h | 8 ++++---- include/tins/internals.h | 10 +++++----- include/tins/packet_writer.h | 2 +- include/tins/pdu_cacher.h | 2 +- include/tins/pdu_option.h | 14 +++++++------- include/tins/sniffer.h | 8 ++++---- include/tins/tcp.h | 4 ++-- include/tins/utils.h | 7 +++++-- src/network_interface.cpp | 3 ++- src/utils.cpp | 3 ++- 13 files changed, 36 insertions(+), 30 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c9d73e8..7ddffe1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,6 +16,7 @@ IF(MSVC) # Disable VC secure checks, since these are not really issues. ADD_DEFINITIONS("-D_CRT_SECURE_NO_WARNINGS=1") ADD_DEFINITIONS("-D_SCL_SECURE_NO_WARNINGS=1") + ADD_DEFINITIONS("-DNOGDI=1") ELSE() SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall") ENDIF() diff --git a/include/tins/dhcp.h b/include/tins/dhcp.h index 4d5c897..55d0ad6 100644 --- a/include/tins/dhcp.h +++ b/include/tins/dhcp.h @@ -503,7 +503,7 @@ private: void write_serialization(uint8_t* buffer, uint32_t total_sz, const PDU* parent); - template + template T search_and_convert(OptionTypes opt) const { const option* option = search_option(opt); if (!option) { diff --git a/include/tins/dhcpv6.h b/include/tins/dhcpv6.h index 7633292..9595d23 100644 --- a/include/tins/dhcpv6.h +++ b/include/tins/dhcpv6.h @@ -887,7 +887,7 @@ private: options_type::const_iterator search_option_iterator(OptionTypes type) const; options_type::iterator search_option_iterator(OptionTypes type); - template