rd_req_dec.c (krb5_rd_req_decoded): Fix -Wall nits
authorTheodore Tso <tytso@mit.edu>
Fri, 9 Jun 1995 22:50:37 +0000 (22:50 +0000)
committerTheodore Tso <tytso@mit.edu>
Fri, 9 Jun 1995 22:50:37 +0000 (22:50 +0000)
configure.in: Remove standardized set of autoconf macros, which are
now handled by CONFIG_RULES.

Makefile.in, faddr_ordr.c: Remove faddr_ordr.c; its function,
krb5_fulladdr_order, isn't used anywhere.

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

src/lib/krb5/krb/ChangeLog
src/lib/krb5/krb/Makefile.in
src/lib/krb5/krb/configure.in
src/lib/krb5/krb/faddr_ordr.c [deleted file]
src/lib/krb5/krb/rd_req_dec.c

index fcceae15c5675b7629ddb52644a5dce19bdea00b..6dc506193a22ab0e1242f499893ab7c14784559f 100644 (file)
@@ -1,3 +1,13 @@
+Fri Jun  9 18:48:43 1995    <tytso@rsx-11.mit.edu>
+
+       * rd_req_dec.c (krb5_rd_req_decoded): Fix -Wall nits
+
+       * configure.in: Remove standardized set of autoconf macros, which
+               are now handled by CONFIG_RULES.
+
+       * Makefile.in, faddr_ordr.c: Remove faddr_ordr.c; its function,
+               krb5_fulladdr_order, isn't used anywhere.
+
 Fri Jun  9 02:42:54 1995  Tom Yu  (tlyu@dragons-lair)
 
        * rd_cred.c (krb5_rd_cred_basic): fix typo (extra "context"
index 154e5aca2e12e45b56b08d62fa7e26c10415e7bc..0a040e71a6ed04ef5768c1b64a3ea18e05cef482 100644 (file)
@@ -32,7 +32,6 @@ OBJS= addr_comp.$(OBJEXT)     \
        encode_kdc.$(OBJEXT)    \
        encrypt_tk.$(OBJEXT)    \
        free_rtree.$(OBJEXT)    \
-       faddr_ordr.$(OBJEXT)    \
        gc_frm_kdc.$(OBJEXT)    \
        gc_via_tkt.$(OBJEXT)    \
        gen_seqnum.$(OBJEXT)    \
@@ -95,7 +94,6 @@ SRCS= $(srcdir)/addr_comp.c   \
        $(srcdir)/encode_kdc.c  \
        $(srcdir)/encrypt_tk.c  \
        $(srcdir)/free_rtree.c  \
-       $(srcdir)/faddr_ordr.c  \
        $(srcdir)/gc_frm_kdc.c  \
        $(srcdir)/gc_via_tkt.c  \
        $(srcdir)/gen_seqnum.c  \
index 6ee82e646fe11d27aa517adbf15170aff5959c35..9bfbc7603a44b26e70247ca9b492da63afb5aacd 100644 (file)
@@ -1,12 +1,8 @@
 AC_INIT(configure.in)
-WITH_CCOPTS
 CONFIG_RULES
-AC_SET_BUILDTOP
-WITH_NETLIB
 AC_PROG_ARCHIVE
 AC_PROG_ARCHIVE_ADD
 AC_PROG_RANLIB
 V5_SHARED_LIB_OBJS
 SubdirLibraryRule([$(OBJS)])
-KRB_INCLUDE
 V5_AC_OUTPUT_MAKEFILE
diff --git a/src/lib/krb5/krb/faddr_ordr.c b/src/lib/krb5/krb/faddr_ordr.c
deleted file mode 100644 (file)
index 6294993..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * lib/krb5/krb/faddr_ordr.c
- *
- * Copyright 1990 by the Massachusetts Institute of Technology.
- * All Rights Reserved.
- *
- * Export of this software from the United States of America may
- *   require a specific license from the United States Government.
- *   It is the responsibility of any person or organization contemplating
- *   export to obtain such a license before exporting.
- * 
- * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
- * distribute this software and its documentation for any purpose and
- * without fee is hereby granted, provided that the above copyright
- * notice appear in all copies and that both that copyright notice and
- * this permission notice appear in supporting documentation, and that
- * the name of M.I.T. not be used in advertising or publicity pertaining
- * to distribution of the software without specific, written prior
- * permission.  M.I.T. makes no representations about the suitability of
- * this software for any purpose.  It is provided "as is" without express
- * or implied warranty.
- * 
- *
- * krb5_fulladdr_order()
- */
-
-#include "k5-int.h"
-
-#ifndef min
-#define min(a,b) ((a) > (b) ? (a) : (b))
-#endif
-
-/*
- * Return an ordering on the two full addresses:  0 if the same,
- * < 0 if first is less than 2nd, > 0 if first is greater than 2nd.
- */
-int
-krb5_fulladdr_order(context, addr1, addr2)
-    krb5_context context;
-    register const krb5_fulladdr *addr1;
-    register const krb5_fulladdr *addr2;
-{
-    int dir;
-    const int minlen = min(addr1->address->length, addr2->address->length);
-    register int i;
-
-    dir = addr1->address->addrtype - addr2->address->addrtype;
-    if (dir)
-       return(dir);
-
-    dir = addr1->address->length - addr2->address->length;
-    if (dir)
-       return(dir);
-
-    for (i = 0; i < minlen; i++) {
-       if ((unsigned char) addr1->address->contents[i] <
-           (unsigned char) addr2->address->contents[i])
-           return -1;
-       else if ((unsigned char) addr1->address->contents[i] >
-                (unsigned char) addr2->address->contents[i])
-           return 1;
-    }
-    if (addr1->port > addr2->port)
-       return(1);
-    else if (addr1->port < addr2->port)
-       return(-1);
-    else
-       return(0);
-}
index f90d439ebee1efe7db4560c0c43d8d42845d9c9c..c450a69c129df5dcd02e6ec61ed03c5f0f864043 100644 (file)
@@ -234,7 +234,7 @@ krb5_rd_req_decoded(context, auth_context, req, server, keytab,
     else
        starttime = req->ticket->enc_part2->times.authtime;
 
-    if (retval = krb5_timeofday(context, &currenttime))
+    if ((retval = krb5_timeofday(context, &currenttime)))
        goto cleanup;
     if (starttime - currenttime > krb5_clockskew) {
        retval = KRB5KRB_AP_ERR_TKT_NYV;        /* ticket not yet valid */
@@ -255,8 +255,8 @@ krb5_rd_req_decoded(context, auth_context, req, server, keytab,
 
     (*auth_context)->remote_seq_number = (*auth_context)->authentp->seq_number;
     (*auth_context)->remote_subkey = (*auth_context)->authentp->subkey;
-    if (retval = krb5_copy_keyblock(context, req->ticket->enc_part2->session,
-                                   &((*auth_context)->keyblock)))
+    if ((retval = krb5_copy_keyblock(context, req->ticket->enc_part2->session,
+                                    &((*auth_context)->keyblock))))
        goto cleanup;
 
     /*