*** empty log message ***
authorJohn Kohl <jtkohl@mit.edu>
Mon, 26 Mar 1990 13:31:15 +0000 (13:31 +0000)
committerJohn Kohl <jtkohl@mit.edu>
Mon, 26 Mar 1990 13:31:15 +0000 (13:31 +0000)
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@410 dc483132-0cff-0310-8789-dd5450dbe970

18 files changed:
src/lib/krb5/free/Imakefile [new file with mode: 0644]
src/lib/krb5/free/f_address.c [new file with mode: 0644]
src/lib/krb5/free/f_ap_rep.c [new file with mode: 0644]
src/lib/krb5/free/f_ap_req.c [new file with mode: 0644]
src/lib/krb5/free/f_authdata.c [new file with mode: 0644]
src/lib/krb5/free/f_authent.c [new file with mode: 0644]
src/lib/krb5/free/f_cksum.c [new file with mode: 0644]
src/lib/krb5/free/f_enc_kdc.c [new file with mode: 0644]
src/lib/krb5/free/f_enc_tkt.c [new file with mode: 0644]
src/lib/krb5/free/f_error.c [new file with mode: 0644]
src/lib/krb5/free/f_kdc_rep.c [new file with mode: 0644]
src/lib/krb5/free/f_keyblock.c [new file with mode: 0644]
src/lib/krb5/free/f_last_req.c [new file with mode: 0644]
src/lib/krb5/free/f_princ.c [new file with mode: 0644]
src/lib/krb5/free/f_priv.c [new file with mode: 0644]
src/lib/krb5/free/f_priv_enc.c [new file with mode: 0644]
src/lib/krb5/free/f_safe.c [new file with mode: 0644]
src/lib/krb5/free/f_ticket.c [new file with mode: 0644]

diff --git a/src/lib/krb5/free/Imakefile b/src/lib/krb5/free/Imakefile
new file mode 100644 (file)
index 0000000..ed91524
--- /dev/null
@@ -0,0 +1,49 @@
+NormalLibraryObjectRule()
+
+OBJS=  \
+       f_address.o     \
+       f_ap_rep.o      \
+       f_ap_req.o      \
+       f_as_req.o      \
+       f_authdata.o    \
+       f_authent.o     \
+       f_cksum.o       \
+       f_enc_kdc.o     \
+       f_enc_tkt.o     \
+       f_error.o       \
+       f_kdc_rep.o     \
+       f_keyblock.o    \
+       f_last_req.o    \
+       f_princ.o       \
+       f_priv.o        \
+       f_priv_enc.o    \
+       f_real_tgs.o    \
+       f_safe.o        \
+       f_tgs_enc.o     \
+       f_tgs_req.o     \
+       f_ticket.o
+
+SRCS=  \
+       f_address.c     \
+       f_ap_rep.c      \
+       f_ap_req.c      \
+       f_as_req.c      \
+       f_authdata.c    \
+       f_authent.c     \
+       f_cksum.c       \
+       f_enc_kdc.c     \
+       f_enc_tkt.c     \
+       f_error.c       \
+       f_kdc_rep.c     \
+       f_keyblock.c    \
+       f_last_req.c    \
+       f_princ.c       \
+       f_priv.c        \
+       f_priv_enc.c    \
+       f_real_tgs.c    \
+       f_safe.c        \
+       f_tgs_enc.c     \
+       f_tgs_req.c     \
+       f_ticket.c
+
+NormalLibraryTarget(kfree,$(OBJS))
diff --git a/src/lib/krb5/free/f_address.c b/src/lib/krb5/free/f_address.c
new file mode 100644 (file)
index 0000000..76c8994
--- /dev/null
@@ -0,0 +1,34 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_address()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_address_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_address(val)
+krb5_address **val;
+{
+    register krb5_address **temp;
+
+    for (temp = val; *temp; temp++) {
+       if ((*temp)->contents)
+           xfree((*temp)->contents);
+       xfree(*temp);
+    }
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_ap_rep.c b/src/lib/krb5/free/f_ap_rep.c
new file mode 100644 (file)
index 0000000..9b18b3b
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_ap_rep()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_ap_rep_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_ap_rep(val)
+register krb5_ap_rep *val;
+{
+    if (val->enc_part.data)
+       xfree(val->enc_part.data);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_ap_req.c b/src/lib/krb5/free/f_ap_req.c
new file mode 100644 (file)
index 0000000..73ec495
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_ap_req()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_ap_req_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_ap_req(val)
+register krb5_ap_req *val;
+{
+    if (val->ticket)
+       krb5_free_ticket(val->ticket);
+    if (val->authenticator.data)
+       xfree(val->authenticator.data);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_authdata.c b/src/lib/krb5/free/f_authdata.c
new file mode 100644 (file)
index 0000000..f7827c1
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_authdata()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_authdata_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_authdata(val)
+krb5_authdata **val;
+{
+    register krb5_authdata **temp;
+
+    for (temp = val; *temp; temp++)
+       xfree(*temp);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_authent.c b/src/lib/krb5/free/f_authent.c
new file mode 100644 (file)
index 0000000..ef23dc0
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_authenticator()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_authent_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_authenticator(val)
+krb5_authenticator *val;
+{
+    if (val->checksum)
+       xfree(val->checksum);
+    if (val->client)
+       krb5_free_principal(val->client);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_cksum.c b/src/lib/krb5/free/f_cksum.c
new file mode 100644 (file)
index 0000000..70ece91
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_checksum()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_cksum_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_checksum(val)
+register krb5_checksum *val;
+{
+    if (val->contents)
+       xfree(val->contents);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_enc_kdc.c b/src/lib/krb5/free/f_enc_kdc.c
new file mode 100644 (file)
index 0000000..8589d38
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_enc_kdc_rep_part()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_enc_kdc_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_enc_kdc_rep_part(val)
+register krb5_enc_kdc_rep_part *val;
+{
+    if (val->session)
+       krb5_free_keyblock(val->session);
+    if (val->last_req)
+       krb5_free_last_req(val->last_req);
+    if (val->server)
+       krb5_free_principal(val->server);
+    if (val->caddrs)
+       krb5_free_address(val->caddrs);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_enc_tkt.c b/src/lib/krb5/free/f_enc_tkt.c
new file mode 100644 (file)
index 0000000..5a0c666
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_enc_tkt_part()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_enc_tkt_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_enc_tkt_part(val)
+krb5_enc_tkt_part *val;
+{
+    if (val->session)
+       krb5_free_keyblock(val->session);
+    if (val->client)
+       krb5_free_principal(val->client);
+    if (val->transited.data)
+       xfree(val->transited.data);
+    if (val->caddrs)
+       krb5_free_address(val->caddrs);
+    if (val->authorization_data)
+       krb5_free_authdata(val->authorization_data);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_error.c b/src/lib/krb5/free/f_error.c
new file mode 100644 (file)
index 0000000..c565f87
--- /dev/null
@@ -0,0 +1,33 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_error()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_error_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_error(val)
+register krb5_error *val;
+{
+    if (val->client)
+       krb5_free_principal(val->client);
+    if (val->server)
+       krb5_free_principal(val->server);
+    if (val->text.data)
+       xfree(val->text.data);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_kdc_rep.c b/src/lib/krb5/free/f_kdc_rep.c
new file mode 100644 (file)
index 0000000..3903c33
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_kdc_rep()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_kdc_rep_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_kdc_rep(val)
+krb5_kdc_rep *val;
+{
+    if (val->client)
+       krb5_free_principal(val->client);
+    if (val->ticket)
+       krb5_free_ticket(val->ticket);
+    if (val->enc_part.data)
+       xfree(val->enc_part.data);
+    if (val->enc_part2)
+       krb5_free_enc_kdc_rep_part(val->enc_part2);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_keyblock.c b/src/lib/krb5/free/f_keyblock.c
new file mode 100644 (file)
index 0000000..61f88e0
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_keyblock()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_keyblock_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_keyblock(val)
+register krb5_keyblock *val;
+{
+    if (val->contents)
+       xfree(val->contents);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_last_req.c b/src/lib/krb5/free/f_last_req.c
new file mode 100644 (file)
index 0000000..d7f4ad6
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_last_req()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_last_req_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_last_req(val)
+krb5_last_req_entry **val;
+{
+    register krb5_last_req_entry **temp;
+
+    for (temp = val; *temp; temp++)
+       xfree(*temp);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_princ.c b/src/lib/krb5/free/f_princ.c
new file mode 100644 (file)
index 0000000..0a73c6c
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_principal()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_princ_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_principal(val)
+krb5_principal val;
+{
+    register krb5_data **temp;
+
+    for (temp = val; *temp; temp++)
+       krb5_free_data(*temp);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_priv.c b/src/lib/krb5/free/f_priv.c
new file mode 100644 (file)
index 0000000..a0265ac
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_priv()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_priv_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_priv(val)
+register krb5_priv *val;
+{
+    if (val->enc_part.data)
+       xfree(val->enc_part.data);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_priv_enc.c b/src/lib/krb5/free/f_priv_enc.c
new file mode 100644 (file)
index 0000000..a1664a0
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_priv_enc_part()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_priv_enc_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_priv_enc_part(val)
+register krb5_priv_enc_part *val;
+{
+    if (val->user_data.data)
+       xfree(val->user_data.data);
+    if (val->addresses)
+       krb5_free_address(val->addresses);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_safe.c b/src/lib/krb5/free/f_safe.c
new file mode 100644 (file)
index 0000000..66b4acf
--- /dev/null
@@ -0,0 +1,33 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_safe()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_safe_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_safe(val)
+register krb5_safe *val;
+{
+    if (val->user_data.data)
+       xfree(val->user_data.data);
+    if (val->addresses)
+       krb5_free_address(val->addresses);
+    if (val->checksum)
+       krb5_free_checksum(val->checksum);
+    xfree(val);
+    return;
+}
diff --git a/src/lib/krb5/free/f_ticket.c b/src/lib/krb5/free/f_ticket.c
new file mode 100644 (file)
index 0000000..5999355
--- /dev/null
@@ -0,0 +1,31 @@
+/*
+ * $Source$
+ * $Author$
+ *
+ * Copyright 1990 by the Massachusetts Institute of Technology.
+ *
+ * For copying and distribution information, please see the file
+ * <krb5/mit-copyright.h>.
+ *
+ * krb5_free_ticket()
+ */
+
+#if !defined(lint) && !defined(SABER)
+static char f_ticket_c [] =
+"$Id$";
+#endif /* !lint & !SABER */
+
+#include <krb5/copyright.h>
+#include <krb5/krb5.h>
+
+void
+krb5_free_ticket(val)
+krb5_ticket *val;
+{
+    if (val->enc_part.data)
+       xfree(val->enc_part.data);
+    if (val->enc_part2)
+       krb5_free_enc_tkt_part(val->enc_part2);
+    xfree(val);
+    return;
+}