X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=crypto%2Fdsa%2Fdsatest.c;h=fc25c9a1b797647e82fb1c4d4681e4d3431d1af7;hb=f846335657f090ed7cc45face7b9955f6684fd5d;hp=363eab62178c87b0fbb40918266f36cce322d0ed;hpb=f5d7a031a3c3e7b1700a67d6dc19daf3718ce6ee;p=oweals%2Fopenssl.git diff --git a/crypto/dsa/dsatest.c b/crypto/dsa/dsatest.c index 363eab6217..fc25c9a1b7 100644 --- a/crypto/dsa/dsatest.c +++ b/crypto/dsa/dsatest.c @@ -134,6 +134,8 @@ int main(int argc, char **argv) if (bio_err == NULL) bio_err=BIO_new_fp(stderr,BIO_NOCLOSE); + CRYPTO_mem_ctrl(CRYPTO_MEM_CHECK_ON); + BIO_printf(bio_err,"test generation of DSA parameters\n"); BIO_printf(bio_err,"expect '.*' followed by 5 lines of '.'s and '+'s\n"); dsa=DSA_generate_parameters(512,seed,20,&counter,&h,dsa_cb, @@ -190,8 +192,9 @@ int main(int argc, char **argv) end: if (!ret) ERR_print_errors(bio_err); - if (bio_err != NULL) BIO_free(bio_err); if (dsa != NULL) DSA_free(dsa); + CRYPTO_mem_leaks(bio_err); + if (bio_err != NULL) BIO_free(bio_err); exit(!ret); return(0); } @@ -206,7 +209,7 @@ static void MS_CALLBACK dsa_cb(int p, int n, char *arg) if (p == 2) { c='*'; ok++; } if (p == 3) c='\n'; BIO_write((BIO *)arg,&c,1); - BIO_flush((BIO *)arg); + (void)BIO_flush((BIO *)arg); if (!ok && (p == 0) && (num > 1)) {