goto end;
}
chaincert = PEM_read_bio_X509(certbio, NULL, NULL, NULL);
+ BIO_free(certbio);
+ certbio = NULL;
+ if (chaincert == NULL) {
+ printf("Unable to load certificate for chain\n");
+ goto end;
+ }
if (!create_ssl_ctx_pair(smeth, cmeth, &sctx,
&cctx, cert, privkey)) {
printf("Unable to create SSL_CTX pair\n");
goto end;
}
- BIO_free(certbio);
- certbio = NULL;
/*
* We assume the supplied certificate is big enough so that if we add
testresult = run_tests(argv[0]);
+ bio_s_mempacket_test_free();
+
#ifndef OPENSSL_NO_CRYPTO_MDEBUG
if (CRYPTO_mem_leaks(err) <= 0)
testresult = 1;
if (SSL_is_dtls(clientssl)) {
s_to_c_bio = BIO_new(bio_s_mempacket_test());
- c_to_s_bio = BIO_new(bio_s_mempacket_test());;
+ c_to_s_bio = BIO_new(bio_s_mempacket_test());
} else {
s_to_c_bio = BIO_new(BIO_s_mem());
c_to_s_bio = BIO_new(BIO_s_mem());