From f4fb6cd4bf4bbfffef4cd3a9a36b3f5c23d447a9 Mon Sep 17 00:00:00 2001 From: Andrew Deason Date: Thu, 10 Jun 2010 10:29:39 -0500 Subject: [PATCH] Remove afsio warnings and errors Fix a few warnings and errors in afsio, so it can compile: - inlcude rx/rx_prototypes.h, not rx_prototypes.h - only declare 'code' in SRXAFSCB_TellMeAboutYourself, and the global rx_mtu in AFS_NT40_ENV, since they're only used on NT40 - remove declarations of the unused variables 'host' in HandleLocalAuth, 'i' in readFile, and 'i' in writeFile Change-Id: If39420cca791669200ccb4d3f46aa5ac7eb89c7d Reviewed-on: http://gerrit.openafs.org/2121 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- src/venus/afsio.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/venus/afsio.c b/src/venus/afsio.c index 585551c3a..35abfc567 100644 --- a/src/venus/afsio.c +++ b/src/venus/afsio.c @@ -99,7 +99,7 @@ #include #include #include -#include +#include #include "../rxkad/md5.h" #ifdef O_LARGEFILE #define afs_stat stat64 @@ -130,7 +130,9 @@ static struct timeval now; struct timezone Timezone; static float seconds, datarate, oldseconds; extern int rxInitDone; +#ifdef AFS_NT40_ENV static afs_int32 rx_mtu = -1; +#endif afs_uint64 transid = 0; afs_uint32 expires = 0; afs_uint32 server_List[MAXHOSTSPERCELL]; @@ -279,7 +281,6 @@ afs_int32 HandleLocalAuth(struct rx_securityClass **sc, afs_int32 *scIndex) { static struct afsconf_dir *tdir = NULL; - afs_uint32 host = 0; afs_int32 code; *sc = NULL; @@ -536,10 +537,8 @@ afs_int32 SRXAFSCB_TellMeAboutYourself(struct rx_call *a_call, struct interfaceAddr * addr, Capabilities *capabilities) { - - int code; - #ifdef AFS_NT40_ENV + int code; int cm_noIPAddr; /* number of client network interfaces */ int cm_IPAddr[CM_MAXINTERFACE_ADDR]; /* client's IP address in host order */ int cm_SubnetMask[CM_MAXINTERFACE_ADDR];/* client's subnet mask in host order*/ @@ -946,7 +945,7 @@ readFile(struct cmd_syndesc *as, void *unused) afs_int32 code; afs_int32 hosts[AFS_MAXHOSTS]; AFSFid Fid; - int i = 0, j; + int j; struct rx_connection *RXConn; struct cellLookup *cl; struct rx_call *tcall; @@ -1151,7 +1150,6 @@ writeFile(struct cmd_syndesc *as, void *unused) afs_int32 hosts[AFS_MAXHOSTS]; afs_uint32 useHost; AFSFid Fid; - int i = 0; struct rx_connection *RXConn; struct cellLookup *cl; struct rx_call *tcall; -- 2.39.5