summaryrefslogtreecommitdiffstats
path: root/src/lib/rpc/clnt_tcp.c
diff options
context:
space:
mode:
authorEzra Peisach <epeisach@mit.edu>2001-06-28 20:46:58 +0000
committerEzra Peisach <epeisach@mit.edu>2001-06-28 20:46:58 +0000
commitab9f9a4a46e93259281d198a9fa9420886acd895 (patch)
tree7bcc54a36ed419869208067efe82fd1084defeea /src/lib/rpc/clnt_tcp.c
parent1af8e1107c28fd2ca3ab55486d0e0061509ec566 (diff)
downloadkrb5-ab9f9a4a46e93259281d198a9fa9420886acd895.tar.gz
krb5-ab9f9a4a46e93259281d198a9fa9420886acd895.tar.xz
krb5-ab9f9a4a46e93259281d198a9fa9420886acd895.zip
* auth.h: Provide full prototype for xdr_des_block
* auth_gssapi.h: Complete prototypes for _svcauth_gssapi_unset_names(). * clnt.h: Prototype dispatch functions and all functions. * clnt_perror.c: Prototype static auth_errmsg(). * clnt_raw.h clnt_tcp.c, clnt_udp.c: Provide prototypes to static functions and match dispatch table prototypes. control function takes void * instead of caddr_t. * pmap_rmt.c: Move prototype for resultproc_t to pmap_clnt.h. * rpc.h: get_myaddress returns int. Add prototypes for callrpc and getrpcport. * rpc_commondata.c (rpc_createerr): When initializing rpc_creaerr use RPC_SUCCESS instead of 0. * get_myaddress.c, rpc_dtablesize.c: Include gssrpc/rpc.h for prototype. * pmap_clnt.h, pmap_prot.h, pmap_rmt.h, rpc_msg.h: Full prototypes for all functions. * svc.c: Provide full prototype for static function. * svc.h: Prototypes for dispatch functions added. Flushed out prototypes for all functions missing prototypes. Added prototype for svcfd_create. * svc_auth.c: Prototypes for all functions referenced. * svc_auth.h: Prototype dispatch functions to svc_auth_ops. * svc_auth_any.c: Replace use of authany_wrap() with a new local function that matches svc_auth_ops dispatch table. * svc_simple.c: Provide prototype for static function universal. Fill in missing types of parameters to gssrpc_registerrpc. * svc_raw.c svc_tcp.c, svc_udp.c: Provide prototypes for static functions and match prototypes in dispatch table. Change getargs and freeargs argument to void * from caddr_t. * xdr.c (xdr_void): Function to match prototype of arguments given. * xdr.h: Provide full prototypes for xdr_ops dispatch table and xdr_void(). * svc_auth_gssapi.c, xdr_alloc.c, xdr_mem.c, xdr_rec.c, xdr_stdio.c: Provide protypes for static functions and match dispatch tables. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13528 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib/rpc/clnt_tcp.c')
-rw-r--r--src/lib/rpc/clnt_tcp.c34
1 files changed, 19 insertions, 15 deletions
diff --git a/src/lib/rpc/clnt_tcp.c b/src/lib/rpc/clnt_tcp.c
index 6f81ea1367..c89950b432 100644
--- a/src/lib/rpc/clnt_tcp.c
+++ b/src/lib/rpc/clnt_tcp.c
@@ -62,15 +62,13 @@ static char sccsid[] = "@(#)clnt_tcp.c 1.37 87/10/05 Copyr 1984 Sun Micro";
extern int errno;
-static int readtcp();
-static int writetcp();
-
-static enum clnt_stat clnttcp_call();
-static void clnttcp_abort();
-static void clnttcp_geterr();
-static bool_t clnttcp_freeres();
-static bool_t clnttcp_control();
-static void clnttcp_destroy();
+static enum clnt_stat clnttcp_call(CLIENT *, rpc_u_int32, xdrproc_t, void *,
+ xdrproc_t, void *, struct timeval);
+static void clnttcp_abort(CLIENT *);
+static void clnttcp_geterr(CLIENT *, struct rpc_err *);
+static bool_t clnttcp_freeres(CLIENT *, xdrproc_t, void *);
+static bool_t clnttcp_control(CLIENT *, int, void *);
+static void clnttcp_destroy(CLIENT *);
static struct clnt_ops tcp_ops = {
clnttcp_call,
@@ -93,6 +91,10 @@ struct ct_data {
XDR ct_xdrs;
};
+static int readtcp(struct ct_data *, caddr_t, int);
+static int writetcp(struct ct_data *, caddr_t, int);
+
+
/*
* Create a client handle for a tcp/ip connection.
* If *sockp<0, *sockp is set to a newly created TCP socket and it is
@@ -225,9 +227,9 @@ clnttcp_call(h, proc, xdr_args, args_ptr, xdr_results, results_ptr, timeout)
register CLIENT *h;
rpc_u_int32 proc;
xdrproc_t xdr_args;
- caddr_t args_ptr;
+ void * args_ptr;
xdrproc_t xdr_results;
- caddr_t results_ptr;
+ void * results_ptr;
struct timeval timeout;
{
register struct ct_data *ct = (struct ct_data *) h->cl_private;
@@ -289,7 +291,7 @@ call_again:
* to avoid leaks, since it may allocate
* memory from partially successful decodes.
*/
- int op = xdrs->x_op;
+ enum xdr_op op = xdrs->x_op;
xdrs->x_op = XDR_FREE;
xdr_replymsg(xdrs, &reply_msg);
xdrs->x_op = op;
@@ -344,7 +346,7 @@ static bool_t
clnttcp_freeres(cl, xdr_res, res_ptr)
CLIENT *cl;
xdrproc_t xdr_res;
- caddr_t res_ptr;
+ void * res_ptr;
{
register struct ct_data *ct = (struct ct_data *)cl->cl_private;
register XDR *xdrs = &(ct->ct_xdrs);
@@ -353,8 +355,10 @@ clnttcp_freeres(cl, xdr_res, res_ptr)
return ((*xdr_res)(xdrs, res_ptr));
}
+/*ARGSUSED*/
static void
-clnttcp_abort()
+clnttcp_abort(cl)
+ CLIENT *cl;
{
}
@@ -362,7 +366,7 @@ static bool_t
clnttcp_control(cl, request, info)
CLIENT *cl;
int request;
- char *info;
+ void *info;
{
register struct ct_data *ct = (struct ct_data *)cl->cl_private;
int len;