All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] if_nametoindex.3: add possible errno for if_nametoindex()
@ 2017-05-09 14:45 Douglas Caetano dos Santos
       [not found] ` <44e09423-9043-26c1-b6e3-7a6eea5be7ff-6ANAkuZINJhwFqzsTH5u/w@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Douglas Caetano dos Santos @ 2017-05-09 14:45 UTC (permalink / raw)
  To: linux-man-u79uwXL29TY76Z2rM5mHXA

Checked against glibc and kernel code: when given name isn't a valid interface,
kernel returns ENODEV and glibc just forwards it.

Signed-off-by: Douglas Caetano dos Santos <douglascs-6ANAkuZINJhwFqzsTH5u/w@public.gmane.org>
---
 man3/if_nametoindex.3 | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/man3/if_nametoindex.3 b/man3/if_nametoindex.3
index 9689cdbd7..cfe49bc91 100644
--- a/man3/if_nametoindex.3
+++ b/man3/if_nametoindex.3
@@ -67,6 +67,14 @@ on error, NULL is returned and
 .I errno
 is set appropriately.
 .SH ERRORS
+.BR if_nametoindex ()
+may fail and set
+.I errno
+if:
+.TP
+.B ENODEV
+No interface found with given name.
+.PP
 .BR if_indextoname ()
 may fail and set
 .I errno
-- 
2.12.1

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] if_nametoindex.3: add possible errno for if_nametoindex()
       [not found] ` <44e09423-9043-26c1-b6e3-7a6eea5be7ff-6ANAkuZINJhwFqzsTH5u/w@public.gmane.org>
@ 2017-05-09 19:19   ` Michael Kerrisk (man-pages)
  0 siblings, 0 replies; 2+ messages in thread
From: Michael Kerrisk (man-pages) @ 2017-05-09 19:19 UTC (permalink / raw)
  To: Douglas Caetano dos Santos, linux-man-u79uwXL29TY76Z2rM5mHXA
  Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w

On 05/09/2017 04:45 PM, Douglas Caetano dos Santos wrote:
> Checked against glibc and kernel code: when given name isn't a valid interface,
> kernel returns ENODEV and glibc just forwards it.

Thanks, Douglas. Applied.

Cheers,

Michael


> Signed-off-by: Douglas Caetano dos Santos <douglascs-6ANAkuZINJhwFqzsTH5u/w@public.gmane.org>
> ---
>  man3/if_nametoindex.3 | 8 ++++++++
>  1 file changed, 8 insertions(+)
> 
> diff --git a/man3/if_nametoindex.3 b/man3/if_nametoindex.3
> index 9689cdbd7..cfe49bc91 100644
> --- a/man3/if_nametoindex.3
> +++ b/man3/if_nametoindex.3
> @@ -67,6 +67,14 @@ on error, NULL is returned and
>  .I errno
>  is set appropriately.
>  .SH ERRORS
> +.BR if_nametoindex ()
> +may fail and set
> +.I errno
> +if:
> +.TP
> +.B ENODEV
> +No interface found with given name.
> +.PP
>  .BR if_indextoname ()
>  may fail and set
>  .I errno
> 


-- 
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-05-09 19:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-09 14:45 [PATCH] if_nametoindex.3: add possible errno for if_nametoindex() Douglas Caetano dos Santos
     [not found] ` <44e09423-9043-26c1-b6e3-7a6eea5be7ff-6ANAkuZINJhwFqzsTH5u/w@public.gmane.org>
2017-05-09 19:19   ` Michael Kerrisk (man-pages)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.