gtpc2m8iC/C++ Language Support User's Guide

tpf_RPC_options-Set TPF- Specific Thread Options

This function sets remote procedure call (RPC) thread options.

Format

#include    <rpc.h>
void        tpf_RPC_options(int options);
 

options
One of the following, specifying whether the associated process exits when this RPC thread entry control block (ECB) exits:

TPF_RPC_OPTIONS_EXIT_PROCESS
If this RPC thread ECB exits, its associated process also exits.

TPF_RPC_OPTIONS_EXIT_THREAD
If this RPC thread ECB exits, its associated process does not exit.

Normal Return

None.

Error Return

None.

Programming Considerations

This application programming interface (API) can be issued only for an RPC threaded ECB.

Note:
If this API is issued for a non-threaded ECB, the API is ignored.

Examples

The following example shows that the process does not exit when the ECB exits.

#include   <rpc.h>
 
/*         If this ECB exits, leave the process running    */
 
           tpf_RPC_options(TPF_RPC_OPTIONS_EXIT_THREAD);

Related Information

None.