VMS Help  —  TCPIP Services, Programming Interfaces, RPC Server Routines, svc_register
    Registers the server program with the Portmapper service.
    Format
      #include  <rpc/rpc.h>
      bool_t  svc_register(SVCXPRT *xprt, u_long prognum, u_long
              versnum, void (*dispatch)(), u_long protocol);

1  –  Arguments

 xprt
    A pointer to an RPC server handle created by any of the server-
    handle creation routines.
 prognum
    The program number associated with the server procedure.
 versnum
    The version number associated with the server procedure.
 dispatch
    The address of the service dispatch procedure that the server
    procedure calls. The procedure dispatch has the following form:
    void dispatch(request, xprt)
    struct svc_req *request;
    SVCXPRT *xprt;
    The svc_run and svc_getreqset call the dispatch routine.
 protocol
    The protocol that the server procedure uses. Values for this
    parameter are zero, IPPROTO_UDP, or IPPROTO_TCP. If protocol is
    zero, the service is not registered with the Portmapper service.

2  –  Description

    Associates prognum and versnum with the service dispatch
    procedure dispatch. If protocol is nonzero, then a mapping of
    the triple [prognum, versnum, protocol] to xprt->xp_port is also
    established with the local Portmapper service.

3  –  Return Values

    TRUE               Indicates success.
    FALSE              Indicates failure.
Close Help