Skip to content

Commit 1c2ba4f

Browse files
committed
internet: removed some unused variables
1 parent 4ec02ed commit 1c2ba4f

File tree

4 files changed

+1
-9
lines changed

4 files changed

+1
-9
lines changed

src/internet-apps/model/dhcp6-server.cc

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,6 @@ Dhcp6Server::SendAdvertise(Ptr<NetDevice> iDev, Dhcp6Header header, Inet6SocketA
160160
// Available address pools and IA information is sent in this option.
161161
for (auto& subnet : m_subnets)
162162
{
163-
Ipv6Address pool = subnet.GetAddressPool();
164-
Ipv6Prefix prefix = subnet.GetPrefix();
165-
Ipv6Address minAddress = subnet.GetMinAddress();
166-
Ipv6Address maxAddress = subnet.GetMaxAddress();
167-
168163
/*
169164
* Find the next available address. Checks the expired address map.
170165
* If there are no expired addresses, it advertises a new address.
@@ -210,6 +205,7 @@ Dhcp6Server::SendAdvertise(Ptr<NetDevice> iDev, Dhcp6Header header, Inet6SocketA
210205
{
211206
// Allocate a new address.
212207
uint8_t minAddrBuf[16];
208+
Ipv6Address minAddress = subnet.GetMinAddress();
213209
minAddress.GetBytes(minAddrBuf);
214210

215211
// Get the latest leased address.

src/internet/model/ipv6-l3-protocol.cc

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1428,7 +1428,6 @@ Ipv6L3Protocol::LocalDeliver(Ptr<const Packet> packet, const Ipv6Header& ip, uin
14281428
Ptr<IpL4Protocol> protocol = nullptr;
14291429
Ptr<Ipv6ExtensionDemux> ipv6ExtensionDemux = m_node->GetObject<Ipv6ExtensionDemux>();
14301430
Ptr<Ipv6Extension> ipv6Extension = nullptr;
1431-
Ipv6Address src = ip.GetSource();
14321431
Ipv6Address dst = ip.GetDestination();
14331432
uint8_t nextHeader = ip.GetNextHeader();
14341433
uint8_t nextHeaderPosition = 0;
@@ -1515,7 +1514,6 @@ Ipv6L3Protocol::LocalDeliver(Ptr<const Packet> packet, const Ipv6Header& ip, uin
15151514
else
15161515
{
15171516
p->RemoveAtStart(nextHeaderPosition);
1518-
/* protocol->Receive (p, src, dst, incomingInterface); */
15191517

15201518
// Options have been processed, and the packet is good.
15211519
// We need to adjust the IP header fields

src/internet/model/ipv6-list-routing.cc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ Ipv6ListRouting::RouteInput(Ptr<const Packet> p,
102102
NS_ASSERT(m_ipv6);
103103
// Check if input device supports IP
104104
NS_ASSERT(m_ipv6->GetInterfaceForDevice(idev) >= 0);
105-
Ipv6Address dst = header.GetDestination();
106105

107106
// Check if input device supports IP forwarding
108107
uint32_t iif = m_ipv6->GetInterfaceForDevice(idev);

src/internet/model/ipv6-static-routing.cc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -559,7 +559,6 @@ Ipv6StaticRouting::GetDefaultRoute()
559559
uint32_t metric = it->second;
560560
Ipv6Prefix mask = j->GetDestNetworkPrefix();
561561
uint16_t maskLen = mask.GetPrefixLength();
562-
Ipv6Address entry = j->GetDestNetwork();
563562

564563
if (maskLen)
565564
{

0 commit comments

Comments
 (0)