interfaces_android.go 510 B

123456789101112131415161718192021
  1. // Copyright (C) 2025 The Syncthing Authors.
  2. //
  3. // This Source Code Form is subject to the terms of the Mozilla Public
  4. // License, v. 2.0. If a copy of the MPL was not distributed with this file,
  5. // You can obtain one at https://mozilla.org/MPL/2.0/.
  6. package netutil
  7. import (
  8. "net"
  9. "github.com/wlynxg/anet"
  10. )
  11. func Interfaces() ([]net.Interface, error) {
  12. return anet.Interfaces()
  13. }
  14. func InterfaceAddrsByInterface(intf *net.Interface) ([]net.Addr, error) {
  15. return anet.InterfaceAddrsByInterface(intf)
  16. }