Commit 7d705b35 authored by Marcin Siodelski's avatar Marcin Siodelski
Browse files

[2317] Eliminated cppcheck errors.

parent 016a1958
......@@ -1118,7 +1118,7 @@ private:
// Check the option definition parameters are valid.
try {
def->validate();
} catch (const isc::Exception ex) {
} catch (const isc::Exception& ex) {
isc_throw(DhcpConfigError, "invalid option definition"
<< " parameters: " << ex.what());
}
......
......@@ -1148,7 +1148,7 @@ private:
// Check the option definition parameters are valid.
try {
def->validate();
} catch (const isc::Exception ex) {
} catch (const isc::Exception& ex) {
isc_throw(DhcpConfigError, "invalid option definition"
<< " parameters: " << ex.what());
}
......
......@@ -404,7 +404,7 @@ void Dhcpv6Srv::sanityCheck(const Pkt6Ptr& pkt, RequirementLevel clientid,
Option::OptionCollection server_ids = pkt->getOptions(D6O_SERVERID);
switch (serverid) {
case FORBIDDEN:
if (server_ids.size() > 0) {
if (!server_ids.empty()) {
isc_throw(RFCViolation, "Exactly 1 server-id option expected, but "
<< server_ids.size() << " received in " << pkt->getName());
}
......
......@@ -81,7 +81,7 @@ public:
params["code"] = "38";
params["data"] = "AB CDEF0105";
params["csv-format"] = "False";
} else if (parameter == "name") {
} else if (parameter == "space") {
params["name"] = "subscriber-id";
params["space"] = param_value;
params["code"] = "38";
......
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