IPX/SPX Programming Manual
Library Routines
HP NonStop IPX/SPX Programming Manual—528022-001
5-75
sap_info, sap_info_nw
serverType (continued)
0474
ODBC server
05C8 to 05D0
Reserved for HP use
05D1 to 05D2
Services and servers using RSC. Reserved for HP customers.
*pBuffer
is a pointer to output buffer that contains the 0 or more SAP entries returned.
bufferLen
is the buffer length, specified by programmer. Range: 60 bytes to 32,767 bytes.
moreFlag
returns the value 1 if there are more SAP entries than fit in the *pBuffer buffer. In
this case, you must then reissue the sap_info function to read the remaining
SAP entries. Input value must be set to 1.
tag
is the tag parameter to be used for the Guardian nowait operation.
Example
The following sample program uses the sap_info call:
#include <ipxapish>
#include <sapapih>
#include <zspic>
#include <zipxc>
char buffer [400] = {0};
zipx_ddl_infosap_def *sapInfo = (zipx_ddl_infosap_def *)buffer;
short moreflag = 0;
short error = 0;
short numEntries = 0;
zipx_ddl_sapentry_def *pEntry = 0;
short i;
unsigned long SapError = 0;
moreFlag = 1;
while (moreFlag) {
error = sap_info