VMS Help  —  TCPIP Services, Programming Interfaces, RPC Client Routines, clntudp_create, Description
    Creates an ONC RPC client handle for the remote program prognum,
    version versnum at address addr. The client uses UDP as the
    transport. The routine is similar to the clnt_create routine,
    except clntudp_create allows you to specify a socket and the UDP
    retransmission time.

    If you specify the port number as zero by using addr->sin_port,
    the Portmapper provides the number of the port on which the
    remote program is listening.

    The clntudp_create routine uses the global variable rpc_
    createerr. rpc_createerr is a structure that contains the most
    recent service creation error. Use rpc_createerr if you want the
    client program to handle the error. The value of rpc_createerr is
    set by any RPC client creation routine that does not succeed. The
    rpc_createerr variable is defined in the CLNT.H file.

    The socket referenced by sockp is copied into a private area for
    RPC to use. It is the client's responsibility to close the socket
    referenced by sockp.

    The authentication scheme for the client, client->cl_auth, gets
    set to null authentication. The calling program can set this to
    something different if necessary.

                                  NOTES
       Since UDP/IP messages can only hold up to 8 KB of encoded
       data, this transport cannot be used for procedures that take
       large arguments or return huge results.

       If addr->sin_port is 0 and the requested program is
       available on the host but the program does not support the
       requested version number, this routine still succeeds. A
       subsequent call to the clnt_call routine will discover the
       version mismatch. Use the clnt_create_vers routine if you
       want to avoid this condition.
Close Help