possible bugfix for 1.1.90 and 1.1.91
Brieuc Jeunhomme
bbp at via.ecp.fr
Wed Jan 21 14:42:56 CET 2004
Hi,
I was doing some tests with 1.1.90 and I have found what seems to be a
memory leak (or maybe I don't use the library the right way?).
The attached patch fixes the leak (for those who don't like reading diff
files as I do, grep for 'fixed by BBP' in 'primegen.c' after applying
it).
--
BBP
-------------- next part --------------
diff -puriN libgcrypt-1.1.91-old/cipher/primegen.c libgcrypt-1.1.91/cipher/primegen.c
--- libgcrypt-1.1.91-old/cipher/primegen.c 2003-12-19 10:27:26.000000000 +0100
+++ libgcrypt-1.1.91/cipher/primegen.c 2004-01-19 22:43:32.000000000 +0100
@@ -489,6 +489,7 @@ prime_generate_internal (int mode,
mpi_free (val_2);
mpi_free (q);
+ mpi_free (q_factor); /* fixed by BBP */
if (! err)
{
More information about the Gcrypt-devel
mailing list