mirror of
https://github.com/mfontanini/libtins
synced 2026-01-23 02:35:57 +01:00
Added NetworkInterface::is_loopback.
This commit is contained in:
@@ -215,6 +215,10 @@ NetworkInterface::Info NetworkInterface::addresses() const {
|
||||
return info;
|
||||
}
|
||||
|
||||
bool NetworkInterface::is_loopback() const {
|
||||
return addresses().ip_addr.is_loopback();
|
||||
}
|
||||
|
||||
NetworkInterface::id_type NetworkInterface::resolve_index(const char *name) {
|
||||
#ifndef WIN32
|
||||
id_type id = if_nametoindex(name);
|
||||
|
||||
Reference in New Issue
Block a user