From 6a387c14431370364dd733a45fed5b52238a56a6 Mon Sep 17 00:00:00 2001 From: Ratan Gupta Date: Thu, 3 Aug 2017 13:26:19 +0530 Subject: Avoid copying of object Change-Id: I1e89863344bf6d93b98793c085ea6755f046749f Signed-off-by: Ratan Gupta --- ethernet_interface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ethernet_interface.cpp') diff --git a/ethernet_interface.cpp b/ethernet_interface.cpp index 3070670..14ccc6c 100644 --- a/ethernet_interface.cpp +++ b/ethernet_interface.cpp @@ -57,7 +57,7 @@ void EthernetInterface::createIPAddressObjects() IP::Protocol addressType = IP::Protocol::IPv4; IP::AddressOrigin origin = IP::AddressOrigin::Static; route::Table routingTable; - for (auto addr : addrs) + for (auto& addr : addrs) { if (addr.addrType == AF_INET6) { -- cgit v1.2.1