mirror of https://github.com/golang/go.git
net: clarify LookupAddr docs on libc's behavior, and alternatives
Text from rsc. Fixes #17093 Change-Id: I13c3018b1584f152b53f8576dd16ebef98aa5182 Reviewed-on: https://go-review.googlesource.com/31720 Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
aa1e063efd
commit
eb15cf16ae
|
|
@ -307,6 +307,9 @@ func (r *Resolver) LookupTXT(ctx context.Context, name string) ([]string, error)
|
|||
|
||||
// LookupAddr performs a reverse lookup for the given address, returning a list
|
||||
// of names mapping to that address.
|
||||
//
|
||||
// When using the host C library resolver, at most one result will be
|
||||
// returned. To bypass the host resolver, use a custom Resolver.
|
||||
func LookupAddr(addr string) (names []string, err error) {
|
||||
return DefaultResolver.lookupAddr(context.Background(), addr)
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue