ispx_get_address(3sapd)
ispx_get_address --
determine the IPX address of a given named server
Synopsis
cc ... -lsaprqsts
#include <netware/sap_srvcs.h>
int ispx_get_address(char
server_name, uint8 server_type,
ipxAddr_t
adrs_ptr, int adrs_cnt);
Description
Given a server name, the ispx_get_address call determines and
returns a list of IPX
addresses corresponding to the named
server. The number of addresses returned is limited by adrs_cnt.
Because this function returns no more than the specified number of addresses,
a client application must allocate a large enough buffer to accept the
addresses. Specifically, the size of the address buffer should be at least
as large as the product of adrs_cnt and the size of
ipxAddr_t.
Parameters
The arguments to this function are:
- server_name
-
specifies the server name
- server_type
-
specifies an object type
- adrs_ptr
-
specifies a buffer where the service addresses are to be returned on
successful completion
- adrs_cnt
-
specifies the maximum number of addresses to be returned
Return values
On completion, the ispx_get_address call returns the number of
addresses if successful or a value less than zero if unsuccessful. On
failure, return values are interpreted as follows:
- [IPXDEV_OPEN_FAILED]
-
the TLI t_open of /dev/ipx failed
- [T_BIND_FAILED]
-
the TLI t_bind call failed
- [INVALID_SERVICE_TYPE]
-
the SAP request type was invalid
- [T_SNDUDATA_FAILED]
-
the TLI t_sndudata call failed, and hence, the
SAP request was not transmitted
- [POLL_FAILED]
-
the poll call failed; the ispx_service_query function
polls the connection end-point until all responses have been processed
- [T_RCVUDATA_FAILED]
-
the TLI t_rcvudata call failed
- [T_UNBIND_FAILED]
-
the TLI t_unbind call failed
- [T_CLOSE_FAILED]
-
the TLI t_close call failed
- [NAME_UNRESOLVED]
-
the name could not be resolved, that is, an address matching the specified
name could not be found
- [MALLOC_FAILED]
-
the buffers required by the library cannot be allocated
- [REALLOC_FAILED]
-
the call to dynamically allocate a larger data buffer for the library
failed (this can happen when a buffer previously allocated by the library
is insufficient to hold all of the allocated data)
References
ispx_advertise(3sapd),
ispx_nsrvr_rqst(3sapd),
ispx_service_query(3sapd)
30 January 1998
© 1998 The Santa Cruz Operation, Inc. All rights reserved.