net.cpp 476 B

1234567891011121314151617181920212223
  1. /*
  2. * Copyright (c) 2021, Gunnar Beutner <gbeutner@serenityos.org>
  3. *
  4. * SPDX-License-Identifier: BSD-2-Clause
  5. */
  6. #include <LibC/errno.h>
  7. #include <LibC/net/if.h>
  8. #include <LibC/netinet/in.h>
  9. in6_addr in6addr_any = IN6ADDR_ANY_INIT;
  10. unsigned int if_nametoindex([[maybe_unused]] const char* ifname)
  11. {
  12. errno = ENODEV;
  13. return -1;
  14. }
  15. char* if_indextoname([[maybe_unused]] unsigned int ifindex, [[maybe_unused]] char* ifname)
  16. {
  17. errno = ENXIO;
  18. return nullptr;
  19. }