rpc_set_binding.3ncs

来自「<B>Digital的Unix操作系统VAX 4.2源码</B>」· 3NCS 代码 · 共 85 行

3NCS
85
字号
.TH rpc_set_binding 3ncs.SH Namerpc_set_binding \- bind an RPC handle to a server (client only).SH Syntax#include <idl/c/rpc.h>void rpc_$set_binding(\fIhandle, sockaddr, slength, status\fP).nfhandle_t \fIhandle\fP;socket_$addr_t *\fIsockaddr\fP;unsigned long \fIslength\fP;status_$t *\fIstatus\fP;.fi.\".SH SYNOPSIS (PASCAL).\".DS.\"\fB%include '/usr/include/idl/pas/rpc.ins.pas'\fR.\".\"\fBprocedure rpc_$set_binding(\fR.\"	\fBin \fIhandle\fB: handle_t;\fR.\"	\fBin \fIsockaddr\fB: socket_$addr_t;\fR.\"	\fBin \fIslength\fB: unsigned32;\fR.\"	\fBout \fIstatus\fB: status_$t);\fR.\".DE.SH Arguments.TP 20\fIhandle\fRAn RPC handle..TP 20\fIsockaddr\fRThe socket address of the server with which the handle is being associated..TP 20\fIslength\fRThe length, in bytes, of \fIsockaddr\fR..TP 20\fIstatus\fRThe completion status.If the completion status returned in.PN status\&.allis equal to.B status_$ok ,then the routine that supplied it was successful..SH DescriptionThe .PN rpc_$set_bindingroutine sets the binding of an RPC handle to the specified server.The handle then identifies a specific object at a specific server.Any subsequent remote procedure calls that a client makes using the handleare sent to this destination..NXR "Interface to the Remote Procedure Call" "rpc_set_binding".PPYou can use this routineeither to set the binding in an unbound handleor to replace the existing binding in a fully bound or bound-to-host handle..SH ExamplesThe following statement sets the binding on the handle .PN hto the first server in the .PN lbresultsarray, which was returned by a previous Location Broker lookup routine,.PN lb_lookup_interface :.EXrpc_$set_binding (h, &lbresults[0].saddr, lbresults[0].saddr_len,                       &status);.EE.SH DiagnosticsThis section lists status codes for errors returned by this .PN rpc_$routine in.PN status\&.all ..TP 20\fBrpc_$cant_bind_sock\fRThe RPC runtime library created a socket but was unable to bind it to a socket address..TP 20\fBrpc_$not_in_call\fRAn internal error..TP 20\fBrpc_$proto_error\fRAn internal protocol error..SH Files.PN /usr/include/idl/c/rpc.h.br.PN /usr/include/idl/rpc.idl.SH See Alsointro(3ncs), rpc_alloc_handle(3ncs), rpc_clear_binding(3ncs), rpc_clear_server_binding(3ncs)

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?