* cmds.c, domacro.c: Cast arguments to isspace() and isdigit()
authorEzra Peisach <epeisach@mit.edu>
Fri, 15 Jun 2001 18:58:55 +0000 (18:58 +0000)
committerEzra Peisach <epeisach@mit.edu>
Fri, 15 Jun 2001 18:58:55 +0000 (18:58 +0000)
from char to int.

* ftp.c: krb5_mk_priv(), krb5_mk_safe() expect C_Block *.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@13350 dc483132-0cff-0310-8789-dd5450dbe970

src/appl/gssftp/ftp/ChangeLog
src/appl/gssftp/ftp/cmds.c
src/appl/gssftp/ftp/domacro.c
src/appl/gssftp/ftp/ftp.c

index ba6f78147117748e68b8572e3a790b466774dd1d..eea5fba37436ad57837636402ea1912cc196e89a 100644 (file)
@@ -1,3 +1,10 @@
+2001-06-15  Ezra Peisach  <epeisach@mit.edu>
+
+       * cmds.c, domacro.c: Cast arguments to isspace() and isdigit()
+       from char to int.
+
+       * ftp.c: krb5_mk_priv(), krb5_mk_safe() expect C_Block *.
+
 2001-05-01  Ken Raeburn  <raeburn@mit.edu>
 
        * cmds.c (setpeer): Port number should be unsigned short.  (Patch
index f0f26df676b33701272e1a61af2d5fd7968fc376..f0da69abf9646ffc233ced8981535b6a94fcbd3f 100644 (file)
@@ -726,14 +726,14 @@ void mput(argc, argv)
                        if (mflag && confirm(argv[0], cp)) {
                                tp = cp;
                                if (mcase) {
-                                       while (*tp && !islower(*tp)) {
+                                       while (*tp && !islower((int) (*tp))) {
                                                tp++;
                                        }
                                        if (!*tp) {
                                                tp = cp;
                                                tp2 = tmpbuf;
                                                while ((*tp2 = *tp) != 0) {
-                                                    if (isupper(*tp2)) {
+                                                    if (isupper((int) *tp2)) {
                                                        *tp2 = 'a' + *tp2 - 'A';
                                                     }
                                                     tp++;
@@ -865,14 +865,14 @@ usage:
        if (loc && mcase) {
                char *tp = argv[1], *tp2, tmpbuf[MAXPATHLEN];
 
-               while (*tp && !islower(*tp)) {
+               while (*tp && !islower((int) *tp)) {
                        tp++;
                }
                if (!*tp) {
                        tp = argv[2];
                        tp2 = tmpbuf;
                        while ((*tp2 = *tp) != 0) {
-                               if (isupper(*tp2)) {
+                               if (isupper((int) *tp2)) {
                                        *tp2 = 'a' + *tp2 - 'A';
                                }
                                tp++;
@@ -995,14 +995,14 @@ void mget(argc, argv)
                if (mflag && confirm(argv[0], cp)) {
                        tp = cp;
                        if (mcase) {
-                               while (*tp && !islower(*tp)) {
+                               while (*tp && !islower((int) *tp)) {
                                        tp++;
                                }
                                if (!*tp) {
                                        tp = cp;
                                        tp2 = tmpbuf;
                                        while ((*tp2 = *tp) != 0) {
-                                               if (isupper(*tp2)) {
+                                               if (isupper((int) *tp2)) {
                                                        *tp2 = 'a' + *tp2 - 'A';
                                                }
                                                tp++;
@@ -2140,7 +2140,7 @@ domap(name)
                                break;
                        case '[':
 LOOP:
-                               if (*++cp2 == '$' && isdigit(*(cp2+1))) { 
+                               if (*++cp2 == '$' && isdigit((int) *(cp2+1))) { 
                                        if (*++cp2 == '0') {
                                                char *cp3 = name;
 
@@ -2165,7 +2165,7 @@ LOOP:
                                                        cp2++;
                                                }
                                                else if (*cp2 == '$' &&
-                                                       isdigit(*(cp2+1))) {
+                                                       isdigit((int) *(cp2+1))) {
                                                        if (*++cp2 == '0') {
                                                           char *cp3 = name;
 
@@ -2217,7 +2217,7 @@ LOOP:
                                }
                                break;
                        case '$':
-                               if (isdigit(*(cp2 + 1))) {
+                               if (isdigit((int) *(cp2 + 1))) {
                                        if (*++cp2 == '0') {
                                                char *cp3 = name;
 
index f76690ffd76c36c9a39198f23f52257647934e09..50684a72be3e038210df70be0034f5b0b5af0e1c 100644 (file)
@@ -75,7 +75,7 @@ void domacro(argc, argv)
 TOP:
        cp1 = macros[i].mac_start;
        while (cp1 != macros[i].mac_end) {
-               while (isspace(*cp1)) {
+               while (isspace((int) *cp1)) {
                        cp1++;
                }
                cp2 = line;
@@ -85,9 +85,9 @@ TOP:
                                 *cp2++ = *++cp1;
                                 break;
                            case '$':
-                                if (isdigit(*(cp1+1))) {
+                                if (isdigit((int) *(cp1+1))) {
                                    j = 0;
-                                   while (isdigit(*++cp1)) {
+                                   while (isdigit((int) (*++cp1))) {
                                          j = 10*j +  *cp1 - '0';
                                    }
                                    cp1--;
index 17be15c3ad85d9ab58f39fd239f51241281baacc..452c7133521a7524b5b8beb2311bdb73d35292da 100644 (file)
@@ -411,9 +411,9 @@ static int secure_command(cmd)
                    if ((length = clevel == PROT_P ?
                        krb_mk_priv((unsigned char *)cmd, (unsigned char *)out,
                                strlen(cmd), schedule,
-                               cred.session, &myctladdr, &hisctladdr)
+                               &cred.session, &myctladdr, &hisctladdr)
                      : krb_mk_safe((unsigned char *)cmd, (unsigned char *)out,
-                               strlen(cmd), cred.session,
+                               strlen(cmd), &cred.session,
                                &myctladdr, &hisctladdr)) == -1) {
                        fprintf(stderr, "krb_mk_%s failed for KERBEROS_V4\n",
                                        clevel == PROT_P ? "priv" : "safe");
@@ -687,12 +687,12 @@ int getreply(expecteof)
                                if ((kerror = safe ?
                                  krb_rd_safe((unsigned char *)ibuf, 
                                              (unsigned int) len,
-                                             cred.session,
+                                             &cred.session,
                                              &hisctladdr, 
                                              &myctladdr, &msg_data)
                                : krb_rd_priv((unsigned char *)ibuf, 
                                              (unsigned int) len,
-                                             schedule, cred.session,
+                                             schedule, &cred.session,
                                              &hisctladdr, &myctladdr,
                                              &msg_data))
                                != KSUCCESS) {
@@ -1990,7 +1990,7 @@ int do_auth()
                                     GSS_C_NO_CREDENTIAL,
                                     &gcontext,
                                     target_name,
-                                    *gss_trials[trial].mech_type,
+                                    (gss_OID_desc *)*gss_trials[trial].mech_type,
                                     GSS_C_MUTUAL_FLAG | GSS_C_REPLAY_FLAG |
                                       (forward ? GSS_C_DELEG_FLAG : 
                                        (unsigned) 0),
@@ -2122,7 +2122,7 @@ int do_auth()
                        fprintf(stderr, "Base 64 decoding failed: %s\n",
                                        radix_error(kerror));
                else if ((kerror = krb_rd_safe(out_buf, (unsigned )i,
-                                              cred.session,
+                                              &cred.session,
                                               &hisctladdr, &myctladdr, 
                                               &msg_data)))
                        fprintf(stderr, "Kerberos V4 krb_rd_safe failed: %s\n",