From bd55307b475d64df64da3e1f4dadf992025e5b14 Mon Sep 17 00:00:00 2001 From: Kyle McDonald Date: Sat, 3 May 2014 17:43:35 -0400 Subject: [PATCH] changed ICMP::check to ICMP::checksum for both the public getter and private setter. closes #10 --- include/icmp.h | 4 ++-- src/icmp.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/icmp.h b/include/icmp.h index 56a9b3c..38b3557 100644 --- a/include/icmp.h +++ b/include/icmp.h @@ -258,7 +258,7 @@ namespace Tins { * * \return Returns the checksum as an unit16_t. */ - uint16_t check() const { return Endian::be_to_host(_icmp.check); } + uint16_t checksum() const { return Endian::be_to_host(_icmp.check); } /** * \brief Getter for the echo id. @@ -377,7 +377,7 @@ namespace Tins { } un; } TINS_END_PACK; - void check(uint16_t new_check); + void checksum(uint16_t new_check); /** \brief Serialices this ICMP PDU. * \param buffer The buffer in which the PDU will be serialized. diff --git a/src/icmp.cpp b/src/icmp.cpp index 1fa5b8c..fce8a1f 100644 --- a/src/icmp.cpp +++ b/src/icmp.cpp @@ -86,7 +86,7 @@ void ICMP::type(Flags new_type) { _icmp.type = new_type; } -void ICMP::check(uint16_t new_check) { +void ICMP::checksum(uint16_t new_check) { _icmp.check = Endian::host_to_be(new_check); }