1
0
mirror of https://github.com/mfontanini/libtins synced 2026-01-30 21:44:26 +01:00

Moved endianness change functions to endianness.h.

This commit is contained in:
Matias Fontanini
2012-09-03 23:58:43 -03:00
parent 279940c398
commit 832a79a1e1
39 changed files with 482 additions and 557 deletions

View File

@@ -26,7 +26,7 @@
#include <algorithm>
#include <vector>
#include "pdu.h"
#include "utils.h"
#include "endianness.h"
#include "ipaddress.h"
#include "hwaddress.h"
@@ -114,18 +114,18 @@ namespace Tins {
* \brief Getter for the xid field.
* \return The xid field for this BootP PDU.
*/
uint32_t xid() const { return Utils::be_to_host(_bootp.xid); }
uint32_t xid() const { return Endian::be_to_host(_bootp.xid); }
/**
* \brief Getter for the secs field.
* \return The secs field for this BootP PDU.
*/
uint16_t secs() const { return Utils::be_to_host(_bootp.secs); }
uint16_t secs() const { return Endian::be_to_host(_bootp.secs); }
/** \brief Getter for the padding field.
* \return The padding field for this BootP PDU.
*/
uint16_t padding() const { return Utils::be_to_host(_bootp.padding); }
uint16_t padding() const { return Endian::be_to_host(_bootp.padding); }
/**
* \brief Getter for the ciaddr field.