rpc_$free_handle Library Routine

Purpose

Frees a Remote Procedure Call (RPC) handle.

Syntax

void rpc_$free_handle ( handle,  status)
handle_t handle;
status_$t *status;

Description

The rpc_$free_handle routine frees an RPC handle by clearing the association between the handle and a server or an object, and then releasing the resources identified by the RPC handle. The client program cannot use a handle after it is freed.

To make multiple RPC calls using the same interface but different socket addresses, replace the binding in an existing handle with the rpc_$set_binding routine instead of creating a new handle with the rpc_$free_handle and rpc_$bind routines.

To free copies of RPC handles created by the rpc_$dup_handle routine, use the rpc_$free_handle routine once for each copy of the handle. However, the RPC runtime library does not differentiate between calling the rpc_$free_handle routine several times on one copy of a handle and calling it one time for each of several copies of a handle. Therefore, if you use duplicate handles, you must ensure that no thread inadvertently makes multiple rpc_$free_handle calls on a single handle.

Note: This routine is used by clients only.

Parameters

Input

Item Description
handle Specifies the RPC handle to be freed.

Output

Item Description
status Points to the completion status.

Examples

To free two copies of a handle, enter:

rpc_$free_handle(handle, &st);
rpc_$free_handle(thread_2_handle, &st);