DCE for the HP e3000 (B3821-90003)
58 Chapter7
Programming with RPC 1.2.1 on MPE/iX
*
* Inquire about the error status returned by the previous DCE call.
*
* The first parameter to this call is a DCE error_status_t presumed
* to have been returned by a preceeding DCE call. The second
* parameter is a string long enough to hold the longest possible
* DCE error string -- the data type dce_error_string_t is defined
* to be a character array of this length. The third parameter is
* another dce error status; this call is unlikely to fail so its
* status is ignored.
*/
dce_error_inq_text(st, dce_err_string, (int *)&_ignore);
PRINT_FUNC(PRINT_HANDLE, "Cannot compose string binding: %s\n",
dce_err_string);
exit(1);
}
/* rpc_binding_from_string_binding() --
* Create a binding handle structure from the string binding. The
* client stub function needs a binding handle; it cannot use the string
* binding form created above.
*
* The first parameter to this call is the string binding generated
* earlier. The second parameter is an RPC binding handle structure;
* a new binding handle will be allocated and stored here -- this
* application must free the storage when it is done with it. The third
* parameter is the DCE return status.
*/
rpc_binding_from_string_binding(string_binding, /* created above */
&bh, /* allocated and returned */
&st); /* error status for this call
*/
if (st != rpc_s_ok) {
dce_error_inq_text(st, dce_err_string, (int *)&_ignore);
PRINT_FUNC(PRINT_HANDLE, "Cannot get a binding handle: %s\n",
dce_err_string);
exit(1);
}