svn rev #21904: trunk/src/lib/rpc/
epeisach@MIT.EDU
epeisach at MIT.EDU
Thu Feb 5 21:45:23 EST 2009
http://src.mit.edu/fisheye/changelog/krb5/?cs=21904
Commit By: epeisach
Log Message:
Cleanup some warnings due to getsockname's third argument is sometimes
unsigned. Use GETSOCKNAME_ARG3_TYPE and fallback to int if not defined.
Changed Files:
U trunk/src/lib/rpc/clnt_tcp.c
U trunk/src/lib/rpc/clnt_udp.c
U trunk/src/lib/rpc/pmap_rmt.c
Modified: trunk/src/lib/rpc/clnt_tcp.c
===================================================================
--- trunk/src/lib/rpc/clnt_tcp.c 2009-02-06 01:07:32 UTC (rev 21903)
+++ trunk/src/lib/rpc/clnt_tcp.c 2009-02-06 02:45:21 UTC (rev 21904)
@@ -64,6 +64,10 @@
#define MCALL_MSG_SIZE 24
+#ifndef GETSOCKNAME_ARG3_TYPE
+#define GETSOCKNAME_ARG3_TYPE int
+#endif
+
static enum clnt_stat clnttcp_call(CLIENT *, rpcproc_t, xdrproc_t, void *,
xdrproc_t, void *, struct timeval);
static void clnttcp_abort(CLIENT *);
@@ -372,7 +376,7 @@
void *info)
{
register struct ct_data *ct = (struct ct_data *)cl->cl_private;
- int len;
+ GETSOCKNAME_ARG3_TYPE len;
switch (request) {
case CLSET_TIMEOUT:
Modified: trunk/src/lib/rpc/clnt_udp.c
===================================================================
--- trunk/src/lib/rpc/clnt_udp.c 2009-02-06 01:07:32 UTC (rev 21903)
+++ trunk/src/lib/rpc/clnt_udp.c 2009-02-06 02:45:21 UTC (rev 21904)
@@ -52,6 +52,9 @@
#include <port-sockets.h>
#include <errno.h>
+#ifndef GETSOCKNAME_ARG3_TYPE
+#define GETSOCKNAME_ARG3_TYPE int
+#endif
/*
* UDP bases client side rpc operations
@@ -82,7 +85,7 @@
struct sockaddr_in cu_raddr;
int cu_rlen;
struct sockaddr_in cu_laddr;
- int cu_llen;
+ GETSOCKNAME_ARG3_TYPE cu_llen;
struct timeval cu_wait;
struct timeval cu_total;
struct rpc_err cu_error;
@@ -235,7 +238,7 @@
register XDR *xdrs;
register int outlen;
register int inlen;
- int fromlen;
+ GETSOCKNAME_ARG3_TYPE fromlen; /* Assumes recvfrom uses same type */
#ifdef FD_SETSIZE
fd_set readfds;
fd_set mask;
Modified: trunk/src/lib/rpc/pmap_rmt.c
===================================================================
--- trunk/src/lib/rpc/pmap_rmt.c 2009-02-06 01:07:32 UTC (rev 21903)
+++ trunk/src/lib/rpc/pmap_rmt.c 2009-02-06 02:45:21 UTC (rev 21904)
@@ -64,6 +64,9 @@
static struct timeval timeout = { 3, 0 };
+#ifndef GETSOCKNAME_ARG3_TYPE
+#define GETSOCKNAME_ARG3_TYPE int
+#endif
/*
* pmapper remote-call-service interface.
@@ -245,7 +248,8 @@
AUTH *unix_auth = authunix_create_default();
XDR xdr_stream;
register XDR *xdrs = &xdr_stream;
- int outlen, inlen, fromlen, nets;
+ int outlen, inlen, nets;
+ GETSOCKNAME_ARG3_TYPE fromlen;
SOCKET sock;
int on = 1;
#ifdef FD_SETSIZE
More information about the cvs-krb5
mailing list