Commit 0c58aace authored by Marcin Siodelski's avatar Marcin Siodelski
Browse files

[2365] Use (un)packOptions functions in classes derived from Option.

parent 69950d29
......@@ -44,7 +44,7 @@ void Option6IA::pack(isc::util::OutputBuffer& buf) {
buf.writeUint32(t1_);
buf.writeUint32(t2_);
LibDHCP::packOptions6(buf, options_);
packOptions(buf);
}
void Option6IA::unpack(OptionBufferConstIter begin,
......@@ -62,7 +62,7 @@ void Option6IA::unpack(OptionBufferConstIter begin,
t2_ = readUint32( &(*begin) );
begin += sizeof(uint32_t);
LibDHCP::unpackOptions6(OptionBuffer(begin, end), options_);
unpackOptions(OptionBuffer(begin, end));
}
std::string Option6IA::toText(int indent /* = 0*/) {
......
......@@ -59,7 +59,7 @@ void Option6IAAddr::pack(isc::util::OutputBuffer& buf) {
buf.writeUint32(valid_);
// parse suboption (there shouldn't be any for IAADDR)
LibDHCP::packOptions6(buf, options_);
packOptions(buf);
}
void Option6IAAddr::unpack(OptionBuffer::const_iterator begin,
......@@ -77,7 +77,8 @@ void Option6IAAddr::unpack(OptionBuffer::const_iterator begin,
valid_ = readUint32( &(*begin) );
begin += sizeof(uint32_t);
LibDHCP::unpackOptions6(OptionBuffer(begin, end), options_);
unpackOptions(OptionBuffer(begin, end));
}
std::string Option6IAAddr::toText(int indent /* =0 */) {
......
......@@ -104,7 +104,7 @@ public:
default:
isc_throw(dhcp::InvalidDataType, "non-integer type");
}
LibDHCP::packOptions6(buf, options_);
packOptions(buf);
}
/// @brief Parses received buffer
......@@ -149,7 +149,7 @@ public:
// of clang complain about unresolved reference to
// OptionDataTypeTraits structure during linking.
begin += data_size_len;
LibDHCP::unpackOptions6(OptionBuffer(begin, end), options_);
unpackOptions(OptionBuffer(begin, end));
}
/// @brief Set option value.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment