Skip to content
Search

C:getnameinfo

lastmod 2019-09-09created 2019-09-094 edits

Looks up and converts an IP address and port into the corresponding host and service names.

Flags

NI_DGRAM
Forces it to return information for a datagram socket.
NI_NAMEREQD
If the hostname cannot be found, a numeric form is returned by default, but with this flag an error is returned
NI_NOFQDN
By default the FQDN is returned; only when the host is local, only the first part of the FQDN is returned
NI_NUMERICHOST
Forces a numeric string to be returned in host instead of using DNS
NI_NUMERICSERV
Forces a decimal port number to be returned; does not search /etc/services.

Favorite site

author Zer0 sitemap