X-Git-Url: http://git.silcnet.org/gitweb/?p=silc.git;a=blobdiff_plain;f=lib%2Fsilcmath%2Fsilcprimegen.c;h=737a09ad8bcf97eccae4a4982b29c45214dce3c2;hp=14719be26dce7cfb8c6b0cee5726a90fe926217f;hb=a24dcffe20a3f0059fb58619b57b488d2bfae5ad;hpb=3464b5361b0d36180cb72996e30b2bfc754b28d4 diff --git a/lib/silcmath/silcprimegen.c b/lib/silcmath/silcprimegen.c index 14719be2..737a09ad 100644 --- a/lib/silcmath/silcprimegen.c +++ b/lib/silcmath/silcprimegen.c @@ -23,8 +23,11 @@ /* * $Id$ * $Log$ - * Revision 1.1 2000/06/27 11:36:51 priikone - * Initial revision + * Revision 1.2 2000/07/05 06:06:52 priikone + * Global cosmetic change. + * + * Revision 1.1.1.1 2000/06/27 11:36:51 priikone + * Importet from internal CVS/Added Log headers. * * */ @@ -247,7 +250,7 @@ int silc_math_gen_prime(SilcInt *prime, unsigned int bits, int verbose) /* Init modulo table with the prime candidate and the primes in the primetable. */ - spmods = silc_malloc(sizeof(primetable) * sizeof(unsigned int)); + spmods = silc_calloc(1, sizeof(primetable) * sizeof(unsigned int)); for (i = 0; primetable[i] != 0; i++) { silc_mp_mod_ui(&tmp, prime, primetable[i]); spmods[i] = silc_mp_get_ui(&tmp);