Commit 1b83c74d authored by Thomas Markwalder's avatar Thomas Markwalder
Browse files

[master] Fixed missing log placeholder in b10-dhcp4

Testing undercovered a missing log place holder in Dhcp4_srv.cc, which
surfaces when a release for a non-existance lease is received.
This has been corrected.
parent dbd014d0
......@@ -295,7 +295,7 @@ intervention (e.g. check if DHCP process has sufficient privileges to
update the database). It may also be triggered if a lease was manually
removed from the database during RELEASE message processing.
% DHCP4_RELEASE_FAIL_NO_LEASE client (client-id %2) tried to release address %1, but there is no lease for such address.
% DHCP4_RELEASE_FAIL_NO_LEASE client (client-id %1, hwaddr %2) tried to release address, %3, but there is no such lease.
This warning message is printed when client attempts to release a lease,
but no such lease is known to the server.
......
......@@ -1276,10 +1276,12 @@ Dhcpv4Srv::processRelease(Pkt4Ptr& release) {
if (!lease) {
// No such lease - bogus release
LOG_DEBUG(dhcp4_logger, DBG_DHCP4_DETAIL, DHCP4_RELEASE_FAIL_NO_LEASE)
.arg(release->getCiaddr().toText())
.arg(release->getHWAddr()->toText())
.arg(client_id ? client_id->toText() : "(no client-id)");
LOG_DEBUG(dhcp4_logger, DBG_DHCP4_DETAIL,
DHCP4_RELEASE_FAIL_NO_LEASE)
.arg(client_id ? client_id->toText() : "(no client-id)")
.arg(release->getHWAddr() ?
release->getHWAddr()->toText() : "(no hwaddr info)")
.arg(release->getCiaddr().toText());
return;
}
......
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