diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2015-10-23 13:09:20 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2015-10-23 13:09:20 +0000 |
commit | 7014fe1ec6b3e2ebaad701c55b928dc8cf00f03e (patch) | |
tree | e048172cff01d7638fdfeee42be3339027137cc2 /lib/libc/hidden | |
parent | fc06a5c531155c38f4ed9b246cc36aacf50d031b (diff) |
Switch if_nameindex(3) to use the new NET_RT_IFNAMES sysctl to get the
list of interface names. At the same time switch if_nametoindex(3) and
if_indextoname(3) to use if_nameindex(3) instead of getifaddrs(3).
if_nameindex(3) exposes much less then getifaddrs(3) and is allowed by
pledge(2).
With and OK deraadt@
Diffstat (limited to 'lib/libc/hidden')
-rw-r--r-- | lib/libc/hidden/net/if.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/hidden/net/if.h b/lib/libc/hidden/net/if.h index 0c183004b8a..95f47e47183 100644 --- a/lib/libc/hidden/net/if.h +++ b/lib/libc/hidden/net/if.h @@ -1,4 +1,4 @@ -/* $OpenBSD: if.h,v 1.1 2015/09/14 10:47:01 guenther Exp $ */ +/* $OpenBSD: if.h,v 1.2 2015/10/23 13:09:19 claudio Exp $ */ /* * Copyright (c) 2015 Philip Guenther <guenther@openbsd.org> * @@ -21,8 +21,8 @@ #include_next <net/if.h> PROTO_NORMAL(if_indextoname); -PROTO_DEPRECATED(if_freenameindex); -PROTO_DEPRECATED(if_nameindex); +PROTO_NORMAL(if_freenameindex); +PROTO_NORMAL(if_nameindex); PROTO_NORMAL(if_nametoindex); #endif /* _LIBC_NET_IF_H_ */ |