VMS Help  —  DCE  DCE_RPC, Application Routines, rpc_binding_copy
 NAME

   rpc_binding_copy - Returns a copy of a binding handle

   Used by client or server applications.

 SYNOPSIS

   #include <dce/rpc.h>

   void rpc_binding_copy( rpc_binding_handle_t source_binding,
                          rpc_binding_handle_t *destination_binding,
                          unsigned32 *status );

 PARAMETERS

   Input

   source_binding
       Specifies the server binding handle whose referenced binding
       information is copied.

   Output

   destination_binding
       Returns the server binding handle that refers to the copied
       binding information.

   status
       Returns the status code from this routine.  This status code
       indicates whether the routine completed successfully or, if not,
       why not.  The possible status codes and their meanings are as
       follows:

       rpc_s_ok      Success.

       rpc_s_invalid_binding
                     Invalid binding handle.

       rpc_s_wrong_kind_of_binding
                     Wrong kind of binding for operation.

 DESCRIPTION

   The rpc_binding_copy() routine copies the server binding information
   referenced by the binding handle specified in the source_binding
   parameter.  This routine returns a new server binding handle for the
   copied binding information. The new server binding handle is returned
   in the destination_binding parameter.

   Use the rpc_binding_copy() routine if you want a change (made to
   binding information by one thread) not to affect the binding infor-
   mation used by other threads.  The explanation of binding handles in
   the rpc_intro reference page has more detail about this use of
   routine rpc_binding_copy().

   After calling this routine, operations performed on the source_binding
   binding handle do not affect the binding information referenced by the
   destination_binding binding handle. Similarly, operations performed on
   the destination_binding binding handle do not affect the binding
   information referenced by the source_binding binding handle.

   If you want the changes made to binding information by one thread to
   affect the binding information used by other threads, your program
   must share a single binding handle across the threads.  In this case
   the application controls binding handle concurrency.

   When an application is finished using the binding handle specified
   by the destination_binding parameter, the application calls the
   rpc_binding_free() routine to release the memory used by the
   destination_binding binding handle and its referenced binding
   information.

 RETURN VALUES

   No value is returned.

 RELATED INFORMATION

   Functions: rpc_binding_free
Close Help