To select options:
1.
Declare an array of at least two elements of the type ACMSDI_OPTION.
2.
Specify in the option variable the name tag for the structure being used.
3.
End an options list by assigning ACMSDI_OPT_END_LIST to the option
variable in the last array element.
Example 2–5 initializes an options list to enable version checking, user-defined
memory allocation, and password expiration checking.
Example 2–5 Initializing an Options List
void *my_malloc_routine(int size);
long pwd_exp_buffer;
void my_free_routine(void *ptr);
ACMSDI_OPTION options[5];
options[0].option = ACMSDI_OPT_CHECK_VERSION;
options[1].option = ACMSDI_OPT_MALLOC_ROUTINE;
options[1].malloc_routine.address = my_malloc_routine;
options[2].option = ACMSDI_OPT_FREE_ROUTINE;
options[2].free_routine.address = my_free_routine;
options[3].option = ACMSDI_OPT_PWD_EXPIRING;
options[3].pwd_expiring_hrs.address = &pwd_exp_buffer;
options[4].option = ACMSDI_OPT_END_LIST;
You can provide the TCP/IP port number during sign-in by using the ACMSDI_
OPT_COMMID option. Example 2–6 shows how to do this in C.
Note
This option is usable with forced nonblocking calls only.
If the environmental variable ACMSDI_TCPIP_PORT_host_node is defined,
the option specified on the acmsdi_sign_in call takes precedence. If neither the
environmental variable nor the sign-in option is specified, the default TCP/IP
port number, 1023, is used.
TP Desktop Connector Portable API Client Services 2–11