From 4d494851582bd76bd01ec76db77a09b406e9e0a9 Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Mon, 6 Oct 1997 15:36:26 +0000 Subject: [PATCH] * destest.c (main): Initialize context to 0 so it will not be treated as unset by purify. * t_verify.c (main): Use krb5_free_context to release memory in use. Essentially purify cleanups... git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10206 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/crypto/des/ChangeLog | 8 ++++++++ src/lib/crypto/des/destest.c | 3 +++ src/lib/crypto/des/t_verify.c | 5 +++++ 3 files changed, 16 insertions(+) diff --git a/src/lib/crypto/des/ChangeLog b/src/lib/crypto/des/ChangeLog index 049f004ae..92a9ea8f3 100644 --- a/src/lib/crypto/des/ChangeLog +++ b/src/lib/crypto/des/ChangeLog @@ -1,3 +1,11 @@ +Mon Oct 6 11:32:51 1997 Ezra Peisach + + * destest.c (main): Initialize context to 0 so it will not be + treated as unset by purify. + + * t_verify.c (main): Use krb5_free_context to release memory in use. + + Sat Feb 22 18:50:35 1997 Richard Basch * Makefile.in: Use some of the new library list build rules in diff --git a/src/lib/crypto/des/destest.c b/src/lib/crypto/des/destest.c index a1f9daf09..1e077a423 100644 --- a/src/lib/crypto/des/destest.c +++ b/src/lib/crypto/des/destest.c @@ -54,6 +54,9 @@ char *argv[]; int num = 0; int error = 0; + /* This is a crock and we know it... We win because + none of these tests rely on a valid context pointer */ + context = 0; /* do some initialisation */ initialize_krb5_error_table(); diff --git a/src/lib/crypto/des/t_verify.c b/src/lib/crypto/des/t_verify.c index 7a2f344de..82a73e21f 100644 --- a/src/lib/crypto/des/t_verify.c +++ b/src/lib/crypto/des/t_verify.c @@ -196,6 +196,8 @@ main(argc,argv) printf("verify: error in zero key test\n"); exit(-1); } + + krb5_free_context(context); exit(0); } @@ -224,6 +226,7 @@ main(argc,argv) printf("verify: error in msb test\n"); exit(-1); } + krb5_free_context(context); exit(0); } @@ -375,6 +378,8 @@ main(argc,argv) }; } printf("verify: N-fold is correct\n\n"); + + krb5_free_context(context); exit(0); } -- 2.26.2