summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorGravatar Karl Ramm <kcr@mit.edu>2008-01-21 03:39:30 +0000
committerGravatar Karl Ramm <kcr@mit.edu>2008-01-21 03:39:30 +0000
commit5bbdaaf2b5b6c3dee89279bd8a045148a39f6385 (patch)
tree2e2c602680b563b4068c8fb718369891a52ea913 /lib
parenta418b69cbced2ce64bf55796fdb890026233e65e (diff)
cleanup various warnings from gcc -Wall
Diffstat (limited to 'lib')
-rw-r--r--lib/ZCkAuth.c4
-rw-r--r--lib/ZCkZAut.c10
-rw-r--r--lib/ZCmpUID.c2
-rw-r--r--lib/ZCmpUIDP.c2
-rw-r--r--lib/ZFlsLocs.c2
-rw-r--r--lib/ZFmtAuth.c10
-rw-r--r--lib/ZFmtNotice.c2
-rw-r--r--lib/ZFmtRaw.c2
-rw-r--r--lib/ZFmtRawLst.c2
-rw-r--r--lib/ZFmtSmRLst.c2
-rw-r--r--lib/ZFmtSmRaw.c2
-rw-r--r--lib/ZFreeNot.c2
-rw-r--r--lib/ZGetLocs.c2
-rw-r--r--lib/ZGetSender.c1
-rw-r--r--lib/ZGetSubs.c2
-rw-r--r--lib/ZGetWGPort.c2
-rw-r--r--lib/ZInit.c4
-rw-r--r--lib/ZLocations.c3
-rw-r--r--lib/ZMkAuth.c45
-rw-r--r--lib/ZOpenPort.c4
-rw-r--r--lib/ZParseNot.c2
-rw-r--r--lib/ZPeekIfNot.c2
-rw-r--r--lib/ZPeekNot.c2
-rw-r--r--lib/ZPeekPkt.c2
-rw-r--r--lib/ZPending.c2
-rw-r--r--lib/ZReadAscii.c2
-rw-r--r--lib/ZReadZcode.c2
-rw-r--r--lib/ZRecvNot.c2
-rw-r--r--lib/ZRecvPkt.c2
-rw-r--r--lib/ZSendList.c2
-rw-r--r--lib/ZSendNot.c2
-rw-r--r--lib/ZSendPkt.c2
-rw-r--r--lib/ZSendRLst.c2
-rw-r--r--lib/ZSendRaw.c2
-rw-r--r--lib/ZSetDest.c2
-rw-r--r--lib/ZSetFD.c2
-rw-r--r--lib/ZSetSrv.c2
-rw-r--r--lib/ZVariables.c2
-rw-r--r--lib/ZWait4Not.c2
-rw-r--r--lib/Zinternal.c17
40 files changed, 77 insertions, 83 deletions
diff --git a/lib/ZCkAuth.c b/lib/ZCkAuth.c
index 418335e..a851463 100644
--- a/lib/ZCkAuth.c
+++ b/lib/ZCkAuth.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZCheckAuthentication_c[] =
+static const char rcsid_ZCheckAuthentication_c[] =
"$Zephyr: /mit/zephyr/src/lib/RCS/ZCheckAuthentication.c,v 1.14 89/03/24 14:17:38 jtkohl Exp Locker: raeburn $";
#endif
@@ -63,6 +63,6 @@ ZCheckAuthentication(ZNotice_t *notice,
/* if mismatched checksum, then the packet was corrupted */
return ((our_checksum == notice->z_checksum) ? ZAUTH_YES : ZAUTH_FAILED);
#else
- ZCheckZcodeAuthentication(notice, from);
+ return ZCheckZcodeAuthentication(notice, from);
#endif
}
diff --git a/lib/ZCkZAut.c b/lib/ZCkZAut.c
index 470e20d..a3d06f9 100644
--- a/lib/ZCkZAut.c
+++ b/lib/ZCkZAut.c
@@ -13,7 +13,7 @@
/* $Header$ */
#ifndef lint
-static char rcsid_ZCheckAuthentication_c[] =
+static const char rcsid_ZCheckAuthentication_c[] =
"$Zephyr: /mit/zephyr/src/lib/RCS/ZCheckAuthentication.c,v 1.14 89/03/24 14:17:38 jtkohl Exp Locker: raeburn $";
#endif
@@ -54,8 +54,8 @@ Code_t ZCheckZcodeAuthentication(ZNotice_t *notice,
krb5_data cksumbuf;
int valid;
char *cksum0_base, *cksum1_base, *cksum2_base;
- char *svcinst, *x, *y;
- char *asn1_data, *key_data;
+ char *x;
+ unsigned char *asn1_data, *key_data;
int asn1_len, key_len, cksum0_len, cksum1_len, cksum2_len;
result = ZGetCreds(&creds);
@@ -120,7 +120,7 @@ Code_t ZCheckZcodeAuthentication(ZNotice_t *notice,
ZChecksum_t our_checksum;
- our_checksum = des_quad_cksum(cksum0_base, NULL, cksum0_len, 0,
+ our_checksum = des_quad_cksum((unsigned char *)cksum0_base, NULL, cksum0_len, 0,
key_data);
if (our_checksum == notice->z_checksum) {
krb5_free_creds(Z_krb5_ctx, creds);
@@ -152,7 +152,7 @@ Code_t ZCheckZcodeAuthentication(ZNotice_t *notice,
return ZAUTH_FAILED;
}
/* HOLDING: creds, asn1_data, cksumbuf.data */
- result = ZReadZcode(notice->z_ascii_checksum,
+ result = ZReadZcode((unsigned char *)notice->z_ascii_checksum,
asn1_data, asn1_len, &asn1_len);
if (result != ZERR_NONE) {
krb5_free_creds(Z_krb5_ctx, creds);
diff --git a/lib/ZCmpUID.c b/lib/ZCmpUID.c
index 53ef450..a448deb 100644
--- a/lib/ZCmpUID.c
+++ b/lib/ZCmpUID.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZCompareUID_c[] = "$Id$";
+static const char rcsid_ZCompareUID_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZCmpUIDP.c b/lib/ZCmpUIDP.c
index 087fc33..abb05a4 100644
--- a/lib/ZCmpUIDP.c
+++ b/lib/ZCmpUIDP.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZCompareUIDPred_c[] = "$Id$";
+static const char rcsid_ZCompareUIDPred_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFlsLocs.c b/lib/ZFlsLocs.c
index 0e533ae..3708b24 100644
--- a/lib/ZFlsLocs.c
+++ b/lib/ZFlsLocs.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFlushLocations_c[] = "$Id$";
+static const char rcsid_ZFlushLocations_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFmtAuth.c b/lib/ZFmtAuth.c
index 1e19f2f..ba64742 100644
--- a/lib/ZFmtAuth.c
+++ b/lib/ZFmtAuth.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatAuthenticNotice_c[] = "$Id$";
+static const char rcsid_ZFormatAuthenticNotice_c[] = "$Id$";
#endif
#include <internal.h>
@@ -19,8 +19,8 @@ static char rcsid_ZFormatAuthenticNotice_c[] = "$Id$";
#if defined(HAVE_KRB4) || defined(HAVE_KRB5)
Code_t
ZFormatAuthenticNotice(ZNotice_t *notice,
- register char *buffer,
- register int buffer_len,
+ char *buffer,
+ int buffer_len,
int *len,
C_Block session)
{
@@ -41,7 +41,7 @@ ZFormatAuthenticNotice(ZNotice_t *notice,
newnotice.z_checksum = 0;
#else
newnotice.z_checksum =
- (ZChecksum_t)des_quad_cksum(buffer, NULL, ptr - buffer, 0, session);
+ (ZChecksum_t)des_quad_cksum((unsigned char *)buffer, NULL, ptr - buffer, 0, session);
#endif
if ((retval = Z_FormatRawHeader(&newnotice, buffer, buffer_len,
&hdrlen, NULL, NULL)) != ZERR_NONE)
@@ -76,8 +76,6 @@ ZFormatAuthenticNoticeV5(ZNotice_t *notice,
int retval, hdrlen, hdr_adj;
krb5_enctype enctype;
krb5_cksumtype cksumtype;
- int valid;
- char *svcinst, *x, *y;
int key_len;
char *cksum_start, *cstart, *cend;
int cksum_len;
diff --git a/lib/ZFmtNotice.c b/lib/ZFmtNotice.c
index f0ad059..0f914f3 100644
--- a/lib/ZFmtNotice.c
+++ b/lib/ZFmtNotice.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatNotice_c[] = "$Id$";
+static const char rcsid_ZFormatNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFmtRaw.c b/lib/ZFmtRaw.c
index c56d747..691ded0 100644
--- a/lib/ZFmtRaw.c
+++ b/lib/ZFmtRaw.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatRawNotice_c[] = "$Id$";
+static const char rcsid_ZFormatRawNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFmtRawLst.c b/lib/ZFmtRawLst.c
index 470b01f..f08040e 100644
--- a/lib/ZFmtRawLst.c
+++ b/lib/ZFmtRawLst.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatRawNoticeList_c[] = "$Id$";
+static const char rcsid_ZFormatRawNoticeList_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFmtSmRLst.c b/lib/ZFmtSmRLst.c
index cc5177a..6b60097 100644
--- a/lib/ZFmtSmRLst.c
+++ b/lib/ZFmtSmRLst.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatRawNoticeList_c[] = "$Id$";
+static const char rcsid_ZFormatRawNoticeList_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFmtSmRaw.c b/lib/ZFmtSmRaw.c
index 3f23d62..3de04ad 100644
--- a/lib/ZFmtSmRaw.c
+++ b/lib/ZFmtSmRaw.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFormatRawNotice_c[] = "$Id$";
+static const char rcsid_ZFormatRawNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZFreeNot.c b/lib/ZFreeNot.c
index 355d0e3..663dbf8 100644
--- a/lib/ZFreeNot.c
+++ b/lib/ZFreeNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZFreeNotice_c[] = "$Id$";
+static const char rcsid_ZFreeNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZGetLocs.c b/lib/ZGetLocs.c
index cbc07fb..1c018da 100644
--- a/lib/ZGetLocs.c
+++ b/lib/ZGetLocs.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZGetLocations_c[] = "$Id$";
+static const char rcsid_ZGetLocations_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZGetSender.c b/lib/ZGetSender.c
index 09ca742..953d4f9 100644
--- a/lib/ZGetSender.c
+++ b/lib/ZGetSender.c
@@ -29,7 +29,6 @@ ZGetSender(void)
krb5_principal principal;
char *prname;
int result;
- char pname[ANAME_SZ], pinst[INST_SZ], prealm[REALM_SZ]; /*XXX*/
#else
#ifdef HAVE_KRB4
char pname[ANAME_SZ], pinst[INST_SZ], prealm[REALM_SZ];
diff --git a/lib/ZGetSubs.c b/lib/ZGetSubs.c
index a762262..465461a 100644
--- a/lib/ZGetSubs.c
+++ b/lib/ZGetSubs.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZGetSubscriptions_c[] = "$Id$";
+static const char rcsid_ZGetSubscriptions_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZGetWGPort.c b/lib/ZGetWGPort.c
index ad3b483..b3ef17c 100644
--- a/lib/ZGetWGPort.c
+++ b/lib/ZGetWGPort.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZGetWGPort_c[] = "$Id$";
+static const char rcsid_ZGetWGPort_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZInit.c b/lib/ZInit.c
index d14543c..8b26f8a 100644
--- a/lib/ZInit.c
+++ b/lib/ZInit.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZInitialize_c[] =
+static const char rcsid_ZInitialize_c[] =
"$Zephyr: /afs/athena.mit.edu/astaff/project/zephyr/src/lib/RCS/ZInitialize.c,v 1.17 89/05/30 18:11:25 jtkohl Exp $";
#endif
@@ -40,7 +40,7 @@ ZInitialize(void)
char addr[4], hostname[MAXHOSTNAMELEN];
struct in_addr servaddr;
struct sockaddr_in sin;
- int s, sinsize = sizeof(sin);
+ unsigned int s, sinsize = sizeof(sin);
Code_t code;
ZNotice_t notice;
#ifdef HAVE_KRB5
diff --git a/lib/ZLocations.c b/lib/ZLocations.c
index 9b580bc..e721a9c 100644
--- a/lib/ZLocations.c
+++ b/lib/ZLocations.c
@@ -12,7 +12,7 @@
*/
#ifndef lint
-static char rcsid_ZLocations_c[] =
+static const char rcsid_ZLocations_c[] =
"$Zephyr: /afs/athena.mit.edu/astaff/project/zephyr/src/lib/RCS/ZLocations.c,v 1.30 90/12/20 03:04:39 raeburn Exp $";
#endif
@@ -105,7 +105,6 @@ Z_SendLocation(char *class,
time_t ourtime;
ZNotice_t notice, retnotice;
char *bptr[3];
- struct hostent *hent;
short wg_port = ZGetWGPort();
if (!location_info_set)
diff --git a/lib/ZMkAuth.c b/lib/ZMkAuth.c
index 7ed6d61..121f813 100644
--- a/lib/ZMkAuth.c
+++ b/lib/ZMkAuth.c
@@ -7,7 +7,7 @@
*
* Copyright (c) 1987 by the Massachusetts Institute of Technology.
* For copying and distribution information, see the file
- * "mit-copyright.h".
+ * "mit-copyright.h".
*/
#include <internal.h>
@@ -48,7 +48,7 @@ ZMakeAuthentication(register ZNotice_t *notice,
CREDENTIALS cred;
C_Block *session;
- result = krb_mk_req(&authent, SERVER_SERVICE,
+ result = krb_mk_req(&authent, SERVER_SERVICE,
SERVER_INSTANCE, __Zephyr_realm, 0);
if (result != MK_AP_OK)
return (result+krb_err_base);
@@ -65,9 +65,9 @@ ZMakeAuthentication(register ZNotice_t *notice,
/* zero length authent is an error, so malloc(0) is not a problem */
if (!notice->z_ascii_authent)
return (ENOMEM);
- if ((result = ZMakeAscii(notice->z_ascii_authent,
- authent.length*3,
- authent.dat,
+ if ((result = ZMakeAscii(notice->z_ascii_authent,
+ authent.length*3,
+ authent.dat,
authent.length)) != ZERR_NONE) {
free(notice->z_ascii_authent);
return (result);
@@ -113,37 +113,34 @@ Code_t
ZMakeZcodeRealmAuthentication(register ZNotice_t *notice,
char *buffer,
int buffer_len,
- int *phdr_len,
+ int *phdr_len,
char *realm)
{
#ifdef HAVE_KRB5
krb5_error_code result;
krb5_creds *creds;
krb5_keyblock *keyblock;
- krb5_enctype enctype;
- krb5_cksumtype cksumtype;
krb5_auth_context authctx;
krb5_data *authent;
- char *svcinst, *x, *y;
- char *cksum_start, *cstart, *cend, *asn1_data;
- int i, cksum_len, zcode_len, asn1_len, phdr_adj;
-
+ char *cksum_start, *cstart, *cend;
+ int cksum_len, zcode_len, phdr_adj;
+
result = ZGetCredsRealm(&creds, realm);
if (result)
return result;
/* HOLDING: creds */
-
+
/* Figure out what checksum type to use */
keyblock = Z_credskey(creds);
/* HOLDING: creds */
-
+
/* Create the authenticator */
result = krb5_auth_con_init(Z_krb5_ctx, &authctx);
if (result) {
krb5_free_creds(Z_krb5_ctx, creds);
return (result);
}
-
+
authent = (krb5_data *)malloc(sizeof(krb5_data));
/* HOLDING: creds, authctx */
@@ -155,7 +152,7 @@ ZMakeZcodeRealmAuthentication(register ZNotice_t *notice,
return (result);
}
/* HOLDING: creds, authent */
-
+
/* Encode the authenticator */
notice->z_auth = 1;
notice->z_authent_len = authent->length;
@@ -167,8 +164,8 @@ ZMakeZcodeRealmAuthentication(register ZNotice_t *notice,
return (ENOMEM);
}
/* HOLDING: creds, authent, notice->z_ascii_authent */
- result = ZMakeZcode(notice->z_ascii_authent, zcode_len,
- authent->data, authent->length);
+ result = ZMakeZcode(notice->z_ascii_authent, zcode_len,
+ (unsigned char *)authent->data, authent->length);
krb5_free_data(Z_krb5_ctx, authent);
if (result) {
free(notice->z_ascii_authent);
@@ -176,7 +173,7 @@ ZMakeZcodeRealmAuthentication(register ZNotice_t *notice,
return (result);
}
/* HOLDING: creds, notice->z_ascii_authent */
-
+
/* format the notice header, with a zero checksum */
result = Z_NewFormatRawHeader(notice, buffer, buffer_len, phdr_len,
&cksum_start, &cksum_len, &cstart, &cend);
@@ -213,7 +210,7 @@ ZGetCredsRealm(krb5_creds **creds_out,
krb5_creds creds_in;
krb5_ccache ccache; /* XXX make this a global or static?*/
int result;
-
+
result = krb5_cc_default(Z_krb5_ctx, &ccache);
if (result)
return result;
@@ -227,20 +224,20 @@ ZGetCredsRealm(krb5_creds **creds_out,
krb5_cc_close(Z_krb5_ctx, ccache);
return result;
}
-
+
result = krb5_cc_get_principal(Z_krb5_ctx, ccache, &creds_in.client);
if (result) {
krb5_free_cred_contents(Z_krb5_ctx, &creds_in); /* I also hope this is ok */
krb5_cc_close(Z_krb5_ctx, ccache);
return result;
}
-
-#ifdef HAVE_KRB5_CREDS_KEYBLOCK_ENCTYPE
+
+#ifdef HAVE_KRB5_CREDS_KEYBLOCK_ENCTYPE
creds_in.keyblock.enctype = ENCTYPE_DES_CBC_CRC; /* XXX? */
#else
creds_in.session.keytype = KEYTYPE_DES; /* XXX? */
#endif
-
+
result = krb5_get_credentials(Z_krb5_ctx, 0, ccache, &creds_in, creds_out);
krb5_cc_close(Z_krb5_ctx, ccache);
krb5_free_cred_contents(Z_krb5_ctx, &creds_in); /* I also hope this is ok */
diff --git a/lib/ZOpenPort.c b/lib/ZOpenPort.c
index 44bf871..3116e9b 100644
--- a/lib/ZOpenPort.c
+++ b/lib/ZOpenPort.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZOpenPort_c[] = "$Id$";
+static const char rcsid_ZOpenPort_c[] = "$Id$";
#endif
#include <internal.h>
@@ -21,7 +21,7 @@ Code_t
ZOpenPort(u_short *port)
{
struct sockaddr_in bindin;
- int len;
+ unsigned int len;
(void) ZClosePort();
diff --git a/lib/ZParseNot.c b/lib/ZParseNot.c
index 7202c47..72a7587 100644
--- a/lib/ZParseNot.c
+++ b/lib/ZParseNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZParseNotice_c[] =
+static const char rcsid_ZParseNotice_c[] =
"$Zephyr: /mit/zephyr/src/lib/RCS/ZParseNotice.c,v 1.22 91/03/29 03:34:46 raeburn Exp $";
#endif
diff --git a/lib/ZPeekIfNot.c b/lib/ZPeekIfNot.c
index bd643f8..3bc3e90 100644
--- a/lib/ZPeekIfNot.c
+++ b/lib/ZPeekIfNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZPeekIfNotice_c[] = "$Id$";
+static const char rcsid_ZPeekIfNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZPeekNot.c b/lib/ZPeekNot.c
index 679382e..18c2026 100644
--- a/lib/ZPeekNot.c
+++ b/lib/ZPeekNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZPeekNotice_c[] = "$Id$";
+static const char rcsid_ZPeekNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZPeekPkt.c b/lib/ZPeekPkt.c
index 6b89f9e..53c5dd7 100644
--- a/lib/ZPeekPkt.c
+++ b/lib/ZPeekPkt.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZPeekPacket_c[] = "$Id$";
+static const char rcsid_ZPeekPacket_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZPending.c b/lib/ZPending.c
index b6cd537..6053c69 100644
--- a/lib/ZPending.c
+++ b/lib/ZPending.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZPending_c[] = "$Id$";
+static const char rcsid_ZPending_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZReadAscii.c b/lib/ZReadAscii.c
index a0bd395..49aaa58 100644
--- a/lib/ZReadAscii.c
+++ b/lib/ZReadAscii.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZReadAscii_c[] = "$Id$";
+static const char rcsid_ZReadAscii_c[] = "$Id$";
#endif /* lint */
#include <internal.h>
diff --git a/lib/ZReadZcode.c b/lib/ZReadZcode.c
index c9fc2f1..dc97990 100644
--- a/lib/ZReadZcode.c
+++ b/lib/ZReadZcode.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZReadZcode_c[] = "$Id$";
+static const char rcsid_ZReadZcode_c[] = "$Id$";
#endif /* lint */
#include <internal.h>
diff --git a/lib/ZRecvNot.c b/lib/ZRecvNot.c
index b6bc442..fbb288a 100644
--- a/lib/ZRecvNot.c
+++ b/lib/ZRecvNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZReceiveNotice_c[] = "$Id$";
+static const char rcsid_ZReceiveNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZRecvPkt.c b/lib/ZRecvPkt.c
index 467268e..3f36ddc 100644
--- a/lib/ZRecvPkt.c
+++ b/lib/ZRecvPkt.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZReceivePacket_c[] = "$Id$";
+static const char rcsid_ZReceivePacket_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSendList.c b/lib/ZSendList.c
index 27176fa..e5d9baa 100644
--- a/lib/ZSendList.c
+++ b/lib/ZSendList.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSendList_c[] = "$Id$";
+static const char rcsid_ZSendList_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSendNot.c b/lib/ZSendNot.c
index 9f59fd3..be23d5a 100644
--- a/lib/ZSendNot.c
+++ b/lib/ZSendNot.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSendNotice_c[] = "$Id$";
+static const char rcsid_ZSendNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSendPkt.c b/lib/ZSendPkt.c
index e542c79..ef1eb6b 100644
--- a/lib/ZSendPkt.c
+++ b/lib/ZSendPkt.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSendPacket_c[] =
+static const char rcsid_ZSendPacket_c[] =
"$Zephyr: /mit/zephyr/src/lib/RCS/ZSendPacket.c,v 1.29 91/03/21 11:57:08 raeburn Exp $";
#endif
diff --git a/lib/ZSendRLst.c b/lib/ZSendRLst.c
index d4d6b7d..3cb4c63 100644
--- a/lib/ZSendRLst.c
+++ b/lib/ZSendRLst.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSendRawList_c[] = "$Id$";
+static const char rcsid_ZSendRawList_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSendRaw.c b/lib/ZSendRaw.c
index 1cd0438..b4eadc3 100644
--- a/lib/ZSendRaw.c
+++ b/lib/ZSendRaw.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSendRawNotice_c[] = "$Id$";
+static const char rcsid_ZSendRawNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSetDest.c b/lib/ZSetDest.c
index 23f75de..4869fbf 100644
--- a/lib/ZSetDest.c
+++ b/lib/ZSetDest.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSetDestAddr_c[] = "$Id$";
+static const char rcsid_ZSetDestAddr_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSetFD.c b/lib/ZSetFD.c
index be16f65..b0f3df7 100644
--- a/lib/ZSetFD.c
+++ b/lib/ZSetFD.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSetFD_c[] = "$Id$";
+static const char rcsid_ZSetFD_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZSetSrv.c b/lib/ZSetSrv.c
index 8b273e1..a3c67c0 100644
--- a/lib/ZSetSrv.c
+++ b/lib/ZSetSrv.c
@@ -11,7 +11,7 @@
*/
#ifndef lint
-static char rcsid_ZSetServerState_c[] = "$Id$";
+static const char rcsid_ZSetServerState_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZVariables.c b/lib/ZVariables.c
index 56e13da..6f0aec9 100644
--- a/lib/ZVariables.c
+++ b/lib/ZVariables.c
@@ -12,7 +12,7 @@
*/
#ifndef lint
-static char rcsid_ZVariables_c[] = "$Id$";
+static const char rcsid_ZVariables_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/ZWait4Not.c b/lib/ZWait4Not.c
index c30dd06..d6c5409 100644
--- a/lib/ZWait4Not.c
+++ b/lib/ZWait4Not.c
@@ -14,7 +14,7 @@
#include "mit-copyright.h"
#ifndef lint
-static char rcsid_ZWaitForNotice_c[] = "$Id$";
+static const char rcsid_ZWaitForNotice_c[] = "$Id$";
#endif
#include <internal.h>
diff --git a/lib/Zinternal.c b/lib/Zinternal.c
index d3958b5..7b4b1c0 100644
--- a/lib/Zinternal.c
+++ b/lib/Zinternal.c
@@ -280,7 +280,8 @@ Z_ReadWait(void)
ZNotice_t notice;
ZPacket_t packet;
struct sockaddr_in olddest, from;
- int from_len, packet_len, zvlen, part, partof;
+ unsigned int from_len;
+ int packet_len, zvlen, part, partof;
char *slash;
Code_t retval;
fd_set fds;
@@ -657,7 +658,7 @@ Z_FormatHeader(ZNotice_t *notice,
Code_t retval;
static char version[BUFSIZ]; /* default init should be all \0 */
struct sockaddr_in name;
- int namelen = sizeof(name);
+ unsigned int namelen = sizeof(name);
if (!notice->z_sender)
notice->z_sender = ZGetSender();
@@ -703,7 +704,7 @@ Z_NewFormatHeader(ZNotice_t *notice,
static char version[BUFSIZ]; /* default init should be all \0 */
struct sockaddr_in name;
struct timeval tv;
- int namelen = sizeof(name);
+ unsigned int namelen = sizeof(name);
if (!notice->z_sender)
notice->z_sender = ZGetSender();
@@ -1278,10 +1279,10 @@ Z_Checksum(krb5_data *cksumbuf,
krb5_keyblock *keyblock,
krb5_cksumtype cksumtype,
char **asn1_data,
- int *asn1_len)
+ unsigned int *asn1_len)
{
krb5_error_code result;
- char *data;
+ unsigned char *data;
int len;
#if HAVE_KRB5_C_MAKE_CHECKSUM
krb5_checksum checksum;
@@ -1353,7 +1354,7 @@ Z_InsertZcodeChecksum(krb5_keyblock *keyblock,
int cksum1_len; /* length of part after checksum */
krb5_data cksumbuf;
krb5_data cksum;
- char *key_data;
+ unsigned char *key_data;
int key_len;
krb5_enctype enctype;
krb5_cksumtype cksumtype;
@@ -1394,7 +1395,7 @@ Z_InsertZcodeChecksum(krb5_keyblock *keyblock,
*/
result = ZMakeZcode(cstart, buffer_len - (plain_len + cksum_len),
- cksum.data, cksum.length);
+ (unsigned char *)cksum.data, cksum.length);
free(cksum.data);
if (!result) {
int zcode_len = strlen(cstart) + 1;
@@ -1421,7 +1422,7 @@ int
Z_krb5_verify_cksum(krb5_keyblock *keyblock,
krb5_data *cksumbuf,
krb5_cksumtype cksumtype,
- char *asn1_data,
+ unsigned char *asn1_data,
int asn1_len)
{
krb5_error_code result;