throbber
eCos Reference Manual
`Chapter 38. TCP/IP Library Reference
`
`Page 1 of 3
`
`Next
`
`gethostbyname
`
`Prev
`
`gethostbyname
`
`GETHOSTBYNAME(3) System Library Functions Manual GETHOSTBYNAME(3)
`NAME
` gethostbyname, gethostbyname2, gethostbyaddr, gethostent, sethostent,
` endhostent, hstrerror, herror - get network host entry
`SYNOPSIS
` #include <netdb.h>
` extern int h_errno;
` struct hostent *
` gethostbyname(const char *name);
` struct hostent *
` gethostbyname2(const char *name, int af);
` struct hostent *
` gethostbyaddr(const char *addr, int len, int af);
` struct hostent *
` gethostent(void);
` void
` sethostent(int stayopen);
` void
` endhostent(void);
` void
` herror(const char *string);
` const char *
` hstrerror(int err);
`DESCRIPTION
` The gethostbyname() and gethostbyaddr() functions each return a pointer
` to an object with the following structure describing an internet host
` referenced by name or by address, respectively. This structure contains
` either information obtained from the name server (i.e., resolver(3) and
` named(8)), broken-out fields from a line in /etc/hosts, or database
` entries supplied by the yp(8) system. resolv.conf(5) describes how the
` particular database is chosen.
` struct hostent {
` char *h_name; /* official name of host */
` char **h_aliases; /* alias list */
` int h_addrtype; /* host address type */
` int h_length; /* length of address */
` char **h_addr_list; /* list of addresses from name server */
` };
`
`http://www.ecos.sourceware.org/docs-2.0/ref/net-common-tcpip-manpages-gethostbyname...
`
`6/15/2013
`
`New Bay Capital, LLC-EX.1006-Page 1 of 3
`
`

`
`gethostbyname
`
`Page 2 of 3
`
` #define h_addr h_addr_list[0] /* address, for backward compatibility */
` The members of this structure are:
` h_name Official name of the host.
` h_aliases A zero-terminated array of alternate names for the host.
` h_addrtype The type of address being returned.
` h_length The length, in bytes, of the address.
` h_addr_list A zero-terminated array of network addresses for the host.
` Host addresses are returned in network byte order.
` h_addr The first address in h_addr_list; this is for backward com-
` patibility.
` The function gethostbyname() will search for the named host in the cur-
` rent domain and its parents using the search lookup semantics detailed in
` resolv.conf(5) and hostname(7).
` gethostbyname2() is an advanced form of gethostbyname() which allows
` lookups in address families other than AF_INET, for example AF_INET6.
` The gethostbyaddr() function will search for the specified address of
` length len in the address family af. The only address family currently
` supported is AF_INET.
` The sethostent() function may be used to request the use of a connected
` TCP socket for queries. If the stayopen flag is non-zero, this sets the
` option to send all queries to the name server using TCP and to retain the
` connection after each call to gethostbyname() or gethostbyaddr(). Other-
` wise, queries are performed using UDP datagrams.
` The endhostent() function closes the TCP connection.
` The herror() function prints an error message describing the failure. If
` its argument string is non-null, it is prepended to the message string
` and separated from it by a colon (`:') and a space. The error message is
` printed with a trailing newline. The contents of the error message is
` the same as that returned by hstrerror() with argument h_errno.
`FILES
` /etc/hosts
` /etc/resolv.conf
`DIAGNOSTICS
` Error return status from gethostbyname(), gethostbyname2(), and
` gethostbyaddr() is indicated by return of a null pointer. The external
` integer h_errno may then be checked to see whether this is a temporary
` failure or an invalid or unknown host.
` The variable h_errno can have the following values:
` HOST_NOT_FOUND No such host is known.
`TRY_AGAIN This is usually a temporary error and means that the
` local server did not receive a response from an authori-
`
`http://www.ecos.sourceware.org/docs-2.0/ref/net-common-tcpip-manpages-gethostbyname...
`
`6/15/2013
`
`New Bay Capital, LLC-EX.1006-Page 2 of 3
`
`

`
`gethostbyname
`
`Page 3 of 3
`
` tative server. A retry at some later time may succeed.
` NO_RECOVERY Some unexpected server failure was encountered. This is
` a non-recoverable error.
` NO_DATA The requested name is valid but does not have an IP
` address; this is not a temporary error. This means that
` the name is known to the name server but there is no
` address associated with this name. Another type of
` request to the name server using this domain name will
` result in an answer; for example, a mail-forwarder may be
` registered for this domain.
`SEE ALSO
` resolver(3), getaddrinfo(3), getnameinfo(3), hosts(5), resolv.conf(5),
` hostname(7), named(8)
`CAVEAT
` If the search routines in resolv.conf(5) decide to read the /etc/hosts
` file, gethostent() and other functions will read the next line of the
` file, re-opening the file if necessary.
` The sethostent() function opens and/or rewinds the file /etc/hosts. If
` the stayopen argument is non-zero, the file will not be closed after each
` call to gethostbyname(), gethostbyname2(), or gethostbyaddr().
` The endhostent() function closes the file.
`HISTORY
` The herror() function appeared in 4.3BSD. The endhostent(),
` gethostbyaddr(), gethostbyname(), gethostent(), and sethostent() func-
` tions appeared in 4.2BSD.
`BUGS
` These functions use static data storage; if the data is needed for future
` use, it should be copied before any subsequent calls overwrite it. Only
` the Internet address formats are currently understood.
` YP does not support any address families other than AF_INET and uses the
` traditional database format.
`BSD March 13, 1997 BSD
`
`Prev
`getaddrinfo
`
`Home
`Up
`
`Next
`getifaddrs
`
`http://www.ecos.sourceware.org/docs-2.0/ref/net-common-tcpip-manpages-gethostbyname...
`
`6/15/2013
`
`New Bay Capital, LLC-EX.1006-Page 3 of 3

This document is available on Docket Alarm but you must sign up to view it.


Or .

Accessing this document will incur an additional charge of $.

After purchase, you can access this document again without charge.

Accept $ Charge
throbber

Still Working On It

This document is taking longer than usual to download. This can happen if we need to contact the court directly to obtain the document and their servers are running slowly.

Give it another minute or two to complete, and then try the refresh button.

throbber

A few More Minutes ... Still Working

It can take up to 5 minutes for us to download a document if the court servers are running slowly.

Thank you for your continued patience.

This document could not be displayed.

We could not find this document within its docket. Please go back to the docket page and check the link. If that does not work, go back to the docket and refresh it to pull the newest information.

Your account does not support viewing this document.

You need a Paid Account to view this document. Click here to change your account type.

Your account does not support viewing this document.

Set your membership status to view this document.

With a Docket Alarm membership, you'll get a whole lot more, including:

  • Up-to-date information for this case.
  • Email alerts whenever there is an update.
  • Full text search for other cases.
  • Get email alerts whenever a new case matches your search.

Become a Member

One Moment Please

The filing “” is large (MB) and is being downloaded.

Please refresh this page in a few minutes to see if the filing has been downloaded. The filing will also be emailed to you when the download completes.

Your document is on its way!

If you do not receive the document in five minutes, contact support at support@docketalarm.com.

Sealed Document

We are unable to display this document, it may be under a court ordered seal.

If you have proper credentials to access the file, you may proceed directly to the court's system using your government issued username and password.


Access Government Site

We are redirecting you
to a mobile optimized page.





Document Unreadable or Corrupt

Refresh this Document
Go to the Docket

We are unable to display this document.

Refresh this Document
Go to the Docket