From ad223f1fab3b91fbad3a078cca672b016aad426f Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Wed, 5 Dec 2001 12:01:17 +0000 Subject: [PATCH] * t_cksum.c (main): Free memory leak in tests git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14040 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/crypto/keyhash_provider/ChangeLog | 4 ++++ src/lib/crypto/keyhash_provider/Makefile.in | 4 ++-- src/lib/crypto/keyhash_provider/t_cksum.c | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/lib/crypto/keyhash_provider/ChangeLog b/src/lib/crypto/keyhash_provider/ChangeLog index 912f10223..2ded8692e 100644 --- a/src/lib/crypto/keyhash_provider/ChangeLog +++ b/src/lib/crypto/keyhash_provider/ChangeLog @@ -1,3 +1,7 @@ +2001-12-05 Ezra Peisach + + * t_cksum.c (main): Free memory leak in tests. + 2001-10-28 Jeff Altman * Makefile.in - added dependency info for hmac_md5.c diff --git a/src/lib/crypto/keyhash_provider/Makefile.in b/src/lib/crypto/keyhash_provider/Makefile.in index 2e42a324c..d1e33571d 100644 --- a/src/lib/crypto/keyhash_provider/Makefile.in +++ b/src/lib/crypto/keyhash_provider/Makefile.in @@ -37,10 +37,10 @@ t_cksum5.o: $(srcdir)/t_cksum.c $(CC) -DMD=5 $(ALL_CFLAGS) -o t_cksum5.o -c $(srcdir)/t_cksum.c t_cksum4: t_cksum4.o $(CRYTPO_DEPLIB) - $(CC_LINK) -o t_cksum4 t_cksum4.o $(K5CRYPTO_LIB) + $(CC_LINK) -o t_cksum4 t_cksum4.o $(K5CRYPTO_LIB) $(LIBS) t_cksum5: t_cksum5.o $(CRYPTO_DEPLIB) - $(CC_LINK) -o t_cksum5 t_cksum5.o $(K5CRYPTO_LIB) + $(CC_LINK) -o t_cksum5 t_cksum5.o $(K5CRYPTO_LIB) $(LIBS) check-unix:: t_cksum4 t_cksum5 $(RUN_SETUP) $(C)t_cksum4 "this is a test" diff --git a/src/lib/crypto/keyhash_provider/t_cksum.c b/src/lib/crypto/keyhash_provider/t_cksum.c index 3fa022fd6..84b2016c4 100644 --- a/src/lib/crypto/keyhash_provider/t_cksum.c +++ b/src/lib/crypto/keyhash_provider/t_cksum.c @@ -132,6 +132,7 @@ main(argc, argv) printf("Verify of bad checksum OK for \"%s\"\n", argv[msgindex]); kret = 0; } + free(newstyle_checksum.data); if (!kret) printf("%d tests passed successfully for MD%d checksum\n", argc-1, MD); return(kret); -- 2.26.2