Opened 7 years ago

Closed 7 years ago

#2760 closed defect (fixed)

Error in code

Reported by: max1976 Owned by:
Priority: medium Milestone: Sprint-DHCP-20130523
Component: dhcp4 Version:
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: DNS Feature Depending on Ticket:
Estimated Difficulty: 0 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

I think that there is a bug in the code:
Subnet4Ptr
Dhcpv4Srv::selectSubnet(const Pkt4Ptr& question) {

Is this relayed message?
IOAddress relay = question->getGiaddr();
if (relay.toText() == "0.0.0.0") {

Yes: Use relay address to select subnet
return (CfgMgr::instance().getSubnet4(relay));

} else {

No: Use client's address to select subnet
return (CfgMgr::instance().getSubnet4(question->getRemoteAddr()));

}

}

In check 'relay.toText() == "0.0.0.0"' should be 'relay.toText() != "0.0.0.0"' .

Subtickets

Change History (4)

comment:1 Changed 7 years ago by jelte

  • Milestone changed from New Tasks to DHCP Outstanding Tasks

comment:2 Changed 7 years ago by stephen

  • Milestone changed from DHCP Outstanding Tasks to Sprint-DHCP-20130509

comment:3 Changed 7 years ago by stephen

  • Milestone changed from Sprint-DHCP-20130509 to Sprint-DHCP-20130523

comment:4 Changed 7 years ago by marcin

  • Resolution set to fixed
  • Status changed from new to closed

This issue has been resolved along with the #2902 ticket.

Note: See TracTickets for help on using tickets.