mirror of https://github.com/mkerrisk/man-pages
getsockname.2: Note that returned address is truncated if buffer is too small
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
cb15903860
commit
f7c494fb23
|
@ -54,10 +54,14 @@ is bound, in the buffer pointed to by
|
|||
The
|
||||
.I namelen
|
||||
argument should be initialized to indicate
|
||||
the amount of space pointed to by
|
||||
the amount of space (in bytes) pointed to by
|
||||
.IR name .
|
||||
On return it contains the actual size of the name
|
||||
returned (in bytes).
|
||||
On return it contains the actual size of the socket address.
|
||||
|
||||
The returned address is truncated if the buffer provided is too small;
|
||||
in this case,
|
||||
.I namelen
|
||||
will return a value greater than was supplied to the call.
|
||||
.SH "RETURN VALUE"
|
||||
On success, zero is returned.
|
||||
On error, \-1 is returned, and
|
||||
|
|
Loading…
Reference in New Issue