[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]

Technical Reference: Communications, Volume 1


callrpc Subroutine

Purpose

Calls the remote procedure on the machine specified by the host parameter.

Library

C Library (libc.a)

Syntax

#include <rpc/rpc.h>


callrpc (host, prognum, versnum, procnum, inproc, in, outproc, out)
char * host;
u_long prognum, versnum, procnum;
xdrproc_t inproc;
char * in;
xdrproc_t outproc;
char * out;

Description

The callrpc subroutine calls a remote procedure identified by the prognum parameter, the versnum parameter, and the procnum parameter on the machine pointed to by the host parameter.

This subroutine uses User Datagram Protocol/Internet Protocol (UDP/IP) as a transport to call a remote procedure. No connection will be made if the server is supported by Transmission Control Protocol/Internet Protocol (TCP/IP). This subroutine does not control time outs or authentication.

Parameters


host Points to the program name of the remote machine.
prognum Specifies the number of the remote program.
versnum Specifies the version number of the remote program.
procnum Specifies the number of the procedure associated with the remote program being called.
inproc Specifies the name of the XDR procedure that encodes the procedure parameters.
in Specifies the address of the procedure arguments.
outproc Specifies the name of the XDR procedure that decodes the procedure results.
out Specifies the address where results are placed.

Return Values

This subroutine returns a value of enum clnt_stat. Use the clnt_perrno subroutine to translate this failure status into a displayed message.

Implementation Specifics

This subroutine is part of Base Operating System (BOS) Runtime.

Related information

The clnt_broadcast subroutine, clnttcp_create subroutine, clntudp_create subroutine, clnt_perrno subroutine, registerrpc subroutine, svc_run subroutine.

The clnt_call macro.

List of RPC Programming References.

TCP/IP Protocols in AIX 5L Version 5.1 System Management Guide: Communications and Networks.

Remote Procedure Call (RPC) Overview for Programming in AIX 5L Version 5.1 Communications Programming Concepts.


[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]