Fix import paths

This commit is contained in:
Mark Qvist 2023-05-05 10:37:22 +02:00
parent 64bdc4c18c
commit 01600b96a4
2 changed files with 3 additions and 2 deletions

View File

@ -906,6 +906,7 @@ class Reticulum:
except Exception as e:
RNS.log("The interface \""+name+"\" could not be created. Check your configuration file for errors!", RNS.LOG_ERROR)
RNS.log("The contained exception was: "+str(e), RNS.LOG_ERROR)
raise e
RNS.panic()
else:
RNS.log("The interface name \""+name+"\" was already used. Check your configuration file for errors!", RNS.LOG_ERROR)

View File

@ -8,11 +8,11 @@ AF_INET6 = socket.AF_INET6.value
AF_INET = socket.AF_INET.value
def interfaces() -> List[str]:
adapters = ifaddr.get_adapters(include_unconfigured=True)
adapters = RNS.vendor.ifaddr.get_adapters(include_unconfigured=True)
return [a.name for a in adapters]
def ifaddresses(ifname) -> dict:
adapters = ifaddr.get_adapters(include_unconfigured=True)
adapters = RNS.vendor.ifaddr.get_adapters(include_unconfigured=True)
ifa = {}
for a in adapters:
if a.name == ifname: