Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/inet - Add ERRORS section covering errno values set...



details:   https://anonhg.NetBSD.org/src/rev/9088cf9b1342
branches:  trunk
changeset: 780347:9088cf9b1342
user:      ginsbach <ginsbach%NetBSD.org@localhost>
date:      Fri Jul 20 19:18:08 2012 +0000

description:
- Add ERRORS section covering errno values set by inet_ntop() and
  inet_pton()

diffstat:

 lib/libc/inet/inet.3 |  32 ++++++++++++++++++++++++++++++--
 1 files changed, 30 insertions(+), 2 deletions(-)

diffs (60 lines):

diff -r 666b14e5f823 -r 9088cf9b1342 lib/libc/inet/inet.3
--- a/lib/libc/inet/inet.3      Fri Jul 20 18:57:27 2012 +0000
+++ b/lib/libc/inet/inet.3      Fri Jul 20 19:18:08 2012 +0000
@@ -1,4 +1,4 @@
-.\"    $NetBSD: inet.3,v 1.3 2012/07/20 14:25:38 ginsbach Exp $
+.\"    $NetBSD: inet.3,v 1.4 2012/07/20 19:18:08 ginsbach Exp $
 .\"
 .\" Copyright (c) 1983, 1990, 1991, 1993
 .\"    The Regents of the University of California.  All rights reserved.
@@ -29,7 +29,7 @@
 .\"
 .\"     @(#)inet.3     8.1 (Berkeley) 6/4/93
 .\"
-.Dd September 22, 2011
+.Dd July 20, 2012
 .Dt INET 3
 .Os
 .Sh NAME
@@ -285,6 +285,33 @@
 and
 .Fn inet_network
 for malformed requests.
+.Sh ERRORS
+The
+.Fn inet_ntop
+and
+.Fn inet_pton
+functions may fail with
+.Bl -tag -width Er
+.It Bq Er EAFNOSUPPORT
+The value of
+.Fa af
+was not
+.Dv AF_INET
+or
+.Dv AF_INET6 .
+.El
+.Pp
+The
+.Fn inet_ntop
+function may fail with
+.Bl -tag -width Er
+.It Bq Er ENOSPC
+The
+.Fa size
+indicated for
+.Fa dst
+was too small to store the presentation form of the network address.
+.El
 .Sh SEE ALSO
 .Xr byteorder 3 ,
 .Xr gethostbyname 3 ,
@@ -362,6 +389,7 @@
 .Fn inet_ntoa
 resides in a static memory area.
 .Pp
+The function
 .Fn inet_addr
 should return a
 .Vt struct in_addr .



Home | Main Index | Thread Index | Old Index