Resolver operations
0x40 Resolver Get Host By Name
Resolves a host name to a network address.
A control terminated name will be passed to the DNS resolver software built into the network module. This call will then wait for a result, and only return when a match is found or timeout occurs.
The returned block at YX+8 onwards is a 'hostent' structure containing a list of IP addresses amongst other information, the lists will remain valid until the next resolver request.
XY+ | Length | On entry | On exit |
---|---|---|---|
4 | 4 | Pointer to name looked up | |
8 | 4 | Pointer to null terminated list of pointers to aliases | |
12 | 4 | IP address type returned, 2 for AF_INET | |
16 | 4 | Length of this address type, 4 for IPv4 | |
20 | 4 | Pointer to null terminated list of pointers to IP address(es) |
0x41 Resolver Get Host
Resolves a host name to a network address.
This is very similar to GetHostByName except that it returns immediately. If the name is already in the DNS cache the result will be filled in and YX+3 is zero, otherwise a request is issued and a 'resolver busy' error returned.
Further calls to GetHost will update YX+3 until either a timeout occurs or the name is found. This allows the request to be sent and the foreground program continue operating, compare this with GetHostByName which blocks until the name has been found.
XY+ | Length | On entry | On exit |
---|---|---|---|
4 | 4 | Pointer to name looked up | |
8 | 4 | Pointer to null terminated list of pointers to aliases | |
12 | 4 | IP address type returned, 2 for AF_INET | |
16 | 4 | Length of this address type, 4 for IPv4 | |
20 | 4 | Pointer to null terminated list of pointers to IP address(es) |
Unsupported actions
The following actions are defined but do nothing. They do not return an error.
Action | Description |
---|---|
0x42 | Resolver Get Cache |
0x43 | Resolver Cache Control |