Commit 26f4192c authored by Tomek Mrugalski's avatar Tomek Mrugalski 🛰
Browse files

cppcheck warnings removed.

parent 86b3f90a
......@@ -100,7 +100,7 @@ LibDHCP::packOptions6(boost::shared_array<uint8_t> data,
offset = (*it).second->pack(data, data_len, offset);
}
}
catch (Exception e) {
catch (const Exception& e) {
cout << "Packet build failed." << endl;
return (-1);
}
......
......@@ -99,17 +99,17 @@ public:
///
/// @return IAID value.
///
unsigned int getIAID() { return iaid_; }
unsigned int getIAID() const { return iaid_; }
/// Returns T1 timer.
///
/// @return T1 value.
unsigned int getT1() { return t1_; }
unsigned int getT1() const { return t1_; }
/// Returns T2 timer.
///
/// @return T2 value.
unsigned int getT2() { return t2_; }
unsigned int getT2() const { return t2_; }
/// @brief returns complete length of option
///
......
......@@ -111,19 +111,19 @@ public:
///
/// @return address
isc::asiolink::IOAddress
getAddress() { return addr_; }
getAddress() const { return addr_; }
/// Returns preferred lifetime of an address.
///
/// @return preferred lifetime (in seconds)
unsigned int
getPreferred() { return preferred_; }
getPreferred() const { return preferred_; }
/// Returns valid lifetime of an address.
///
/// @return valid lifetime (in seconds)
unsigned int
getValid() { return valid_; }
getValid() const { return valid_; }
/// returns data length (data length + DHCPv4/DHCPv6 option header)
virtual unsigned short
......
Markdown is supported
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