mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-08-30 05:06:49 +08:00
More ansifications.
This commit is contained in:
@@ -74,14 +74,17 @@ static const struct timeval timeout = { 3, 0 };
|
||||
* programs to do a lookup and call in one step.
|
||||
*/
|
||||
enum clnt_stat
|
||||
pmap_rmtcall(addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout,
|
||||
port_ptr)
|
||||
struct sockaddr_in *addr;
|
||||
u_long prog, vers, proc;
|
||||
xdrproc_t xdrargs, xdrres;
|
||||
caddr_t argsp, resp;
|
||||
struct timeval tout;
|
||||
u_long *port_ptr;
|
||||
pmap_rmtcall(
|
||||
struct sockaddr_in *addr,
|
||||
u_long prog,
|
||||
u_long vers,
|
||||
u_long proc,
|
||||
xdrproc_t xdrargs,
|
||||
caddr_t argsp,
|
||||
xdrproc_t xdrres,
|
||||
caddr_t resp,
|
||||
struct timeval tout,
|
||||
u_long *port_ptr)
|
||||
{
|
||||
int sock = -1;
|
||||
CLIENT *client;
|
||||
@@ -122,9 +125,9 @@ pmap_rmtcall(addr, prog, vers, proc, xdrargs, argsp, xdrres, resp, tout,
|
||||
* written for XDR_ENCODE direction only
|
||||
*/
|
||||
bool_t
|
||||
xdr_rmtcall_args(xdrs, cap)
|
||||
XDR *xdrs;
|
||||
struct rmtcallargs *cap;
|
||||
xdr_rmtcall_args(
|
||||
XDR *xdrs,
|
||||
struct rmtcallargs *cap)
|
||||
{
|
||||
u_int lenposition, argposition, position;
|
||||
|
||||
@@ -156,9 +159,9 @@ xdr_rmtcall_args(xdrs, cap)
|
||||
* written for XDR_DECODE direction only
|
||||
*/
|
||||
bool_t
|
||||
xdr_rmtcallres(xdrs, crp)
|
||||
XDR *xdrs;
|
||||
struct rmtcallres *crp;
|
||||
xdr_rmtcallres(
|
||||
XDR *xdrs,
|
||||
struct rmtcallres *crp)
|
||||
{
|
||||
caddr_t port_ptr;
|
||||
|
||||
@@ -244,15 +247,15 @@ getbroadcastnets(
|
||||
typedef bool_t (*resultproc_t)(caddr_t, struct sockaddr_in *);
|
||||
|
||||
enum clnt_stat
|
||||
clnt_broadcast(prog, vers, proc, xargs, argsp, xresults, resultsp, eachresult)
|
||||
u_long prog; /* program number */
|
||||
u_long vers; /* version number */
|
||||
u_long proc; /* procedure number */
|
||||
xdrproc_t xargs; /* xdr routine for args */
|
||||
caddr_t argsp; /* pointer to args */
|
||||
xdrproc_t xresults; /* xdr routine for results */
|
||||
caddr_t resultsp; /* pointer to results */
|
||||
resultproc_t eachresult; /* call with each result obtained */
|
||||
clnt_broadcast(
|
||||
u_long prog, /* program number */
|
||||
u_long vers, /* version number */
|
||||
u_long proc, /* procedure number */
|
||||
xdrproc_t xargs, /* xdr routine for args */
|
||||
caddr_t argsp, /* pointer to args */
|
||||
xdrproc_t xresults, /* xdr routine for results */
|
||||
caddr_t resultsp, /* pointer to results */
|
||||
resultproc_t eachresult /* call with each result obtained */ )
|
||||
{
|
||||
enum clnt_stat stat = RPC_SUCCESS; /* to avoid warning */
|
||||
AUTH *unix_auth = authunix_create_default();
|
||||
|
||||
Reference in New Issue
Block a user