1
0
mirror of https://github.com/mfontanini/libtins synced 2026-01-23 02:35:57 +01:00

Removed the useless PDU::flag member. Added a PDU concatenation operator.

This commit is contained in:
Matias Fontanini
2012-10-07 18:51:06 -03:00
parent da60d99f98
commit 153bcecc35
24 changed files with 169 additions and 89 deletions

View File

@@ -26,17 +26,15 @@
namespace Tins {
PDU::PDU(uint32_t flag, PDU *next_pdu) : _flag(flag), _inner_pdu(next_pdu) {
PDU::PDU(PDU *next_pdu) : _inner_pdu(next_pdu) {
}
PDU::PDU(const PDU &other) : _inner_pdu(0) {
_flag = other.flag();
copy_inner_pdu(other);
}
PDU &PDU::operator=(const PDU &other) {
_flag = other.flag();
copy_inner_pdu(other);
return *this;
}
@@ -68,10 +66,6 @@ PDU *PDU::recv_response(PacketSender &) {
return false;
}
void PDU::flag(uint32_t new_flag) {
_flag = new_flag;
}
void PDU::inner_pdu(PDU *next_pdu) {
delete _inner_pdu;
_inner_pdu = next_pdu;