shill: Naming and lint cleanup pass
Reduce some double-speak in IPAddress constants. Do a cursory
glint pass and clean up a few no-brainer issues.
BUG=None
TEST=Re-run unit tests
Change-Id: I063cd72111bd1f6321f81c6c6591b9f51d87434d
Reviewed-on: http://gerrit.chromium.org/gerrit/7181
Reviewed-by: Paul Stewart <pstew@chromium.org>
Tested-by: Paul Stewart <pstew@chromium.org>
diff --git a/device_info.cc b/device_info.cc
index b905d56..611e039 100644
--- a/device_info.cc
+++ b/device_info.cc
@@ -250,6 +250,7 @@
}
void DeviceInfo::FlushAddresses(int interface_index) const {
+ VLOG(2) << __func__ << "(" << interface_index << ")";
const Info *info = GetInfo(interface_index);
if (!info) {
return;
@@ -257,7 +258,7 @@
const vector<AddressData> &addresses = info->ip_addresses;
vector<AddressData>::const_iterator iter;
for (iter = addresses.begin(); iter != addresses.end(); ++iter) {
- if (iter->address.family() == IPAddress::kAddressFamilyIPv4 ||
+ if (iter->address.family() == IPAddress::kFamilyIPv4 ||
(iter->scope == RT_SCOPE_UNIVERSE &&
(iter->flags & ~IFA_F_TEMPORARY) == 0)) {
VLOG(2) << __func__ << ": removing ip address from interface "
@@ -309,6 +310,7 @@
}
void DeviceInfo::AddressMsgHandler(const RTNLMessage &msg) {
+ VLOG(2) << __func__;
DCHECK(msg.type() == RTNLMessage::kTypeAddress);
int interface_index = msg.interface_index();
if (!ContainsKey(infos_, interface_index)) {