lrt_tpinitialize
Enables a client to join a System/T application.
int lrt_tpinitialize( ["usrname=value",] ["cltname=value", ] ["passwd=value", ] [grpname=value,] [flags= value, ] [datalen=value, ] [data=value, ] LRT_END_OF_PARAMS );
| value | Optional list of parameters which indicate how the fields of TPINIT buffer are filled. The first four parameters, user name, client name, password, and group name, are strings.The flags indicate the method for unsolicited notification and system access.The data length is the length of the application–specific data that is passed to the server in the "data=" option. |
The list of parameters must end with LRT_END_OF_PARAMS.
The lrt_tpinitialize function enables a client to join a System/T application. This replaces the TVG_tpinit function.
If the parameters are not specified, then the buffer is filled with default values: an empty string for string fields (usrname, ctlname, passswd, grpname), 0 for numeric fields (datalen, flags) and no data for the data field.
Return Values
If the function ends with an error, it returns -1 and sets the error code in tperrno.
Parameterization
The following argument(s) can be parameterized using standard parameterization:
username
password
groupname
clientname
Note that only the portion after the equal sign is parameterized (e.g., for "name=username", username can be parameterized and not "name=").
Example
In the following example, the lrt_tpinitialize statement sets the user name to "Smith", client name to "bankapp", the password to "mypasswd". The flag is set to TPU_DIP, a constant used in Tuxedo to indicate unsolicited notification by dip-in. The group name is set to blank, data len is set to 0 and there is no data.
/* Enable the bankapp client to join a System/T application*/
lrt_tpinitialize("usrname=Smith", "ctlname=bankapp", "passwd=mypasswd", "flags=TPU_DIP");

