refactor(network): codestyle and error handling
This commit is contained in:
parent
50e782e028
commit
75cc1bc318
|
@ -285,8 +285,12 @@ void waybar::modules::Network::getInterfaceAddress() {
|
||||||
}
|
}
|
||||||
ifa = ifa->ifa_next;
|
ifa = ifa->ifa_next;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
freeifaddrs(ifaddr);
|
freeifaddrs(ifaddr);
|
||||||
|
} else {
|
||||||
|
ipaddr_.clear();
|
||||||
|
netmask_.clear();
|
||||||
|
cidr_ = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int waybar::modules::Network::netlinkRequest(int fd, void *req,
|
int waybar::modules::Network::netlinkRequest(int fd, void *req,
|
||||||
|
|
Loading…
Reference in New Issue