diff options
| author | claudio <> | 2005-03-12 00:02:07 +0000 |
|---|---|---|
| committer | claudio <> | 2005-03-12 00:02:07 +0000 |
| commit | 9a03506f8308b6023a12f108a2072feb958607a6 (patch) | |
| tree | f8754052950140bbfb8cbaf2438f8dd5af00cd94 /src/lib/libc | |
| parent | 541826334ab9e543a530dde3aad96c2bd027f85d (diff) | |
| download | openbsd-9a03506f8308b6023a12f108a2072feb958607a6.tar.gz openbsd-9a03506f8308b6023a12f108a2072feb958607a6.tar.bz2 openbsd-9a03506f8308b6023a12f108a2072feb958607a6.zip | |
There is no need to call freeaddrinfo() in case of an error.
getaddrinfo() does that already by itself.
OK jmc@ beck@
Diffstat (limited to 'src/lib/libc')
| -rw-r--r-- | src/lib/libc/net/getaddrinfo.3 | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/lib/libc/net/getaddrinfo.3 b/src/lib/libc/net/getaddrinfo.3 index fd9f7fece5..b82dda5937 100644 --- a/src/lib/libc/net/getaddrinfo.3 +++ b/src/lib/libc/net/getaddrinfo.3 | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | .\" $OpenBSD: getaddrinfo.3,v 1.39 2005/01/29 00:49:47 jmc Exp $ | 1 | .\" $OpenBSD: getaddrinfo.3,v 1.40 2005/03/12 00:02:07 claudio Exp $ |
| 2 | .\" $KAME: getaddrinfo.3,v 1.36 2005/01/05 03:23:05 itojun Exp $ | 2 | .\" $KAME: getaddrinfo.3,v 1.36 2005/01/05 03:23:05 itojun Exp $ |
| 3 | .\" | 3 | .\" |
| 4 | .\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") | 4 | .\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC") |
| @@ -279,6 +279,11 @@ structure created by a call to | |||
| 279 | returns zero on success or one of the error codes listed in | 279 | returns zero on success or one of the error codes listed in |
| 280 | .Xr gai_strerror 3 | 280 | .Xr gai_strerror 3 |
| 281 | if an error occurs. | 281 | if an error occurs. |
| 282 | If an error occurs, no memory is allocated by | ||
| 283 | .Fn getaddrinfo , | ||
| 284 | therefore it is not necessary to release the | ||
| 285 | .Li addrinfo | ||
| 286 | structure(s). | ||
| 282 | .Sh EXAMPLES | 287 | .Sh EXAMPLES |
| 283 | The following code tries to connect to | 288 | The following code tries to connect to |
| 284 | .Dq Li www.kame.net | 289 | .Dq Li www.kame.net |
