adjust macro guard in example client

This commit is contained in:
Jacob Barthelmeh
2021-12-08 13:45:37 -07:00
parent 9a07b3af9b
commit ad078a7358

View File

@ -1533,7 +1533,7 @@ static const char* client_usage_msg[][70] = {
static void showPeerPEM(WOLFSSL* ssl)
{
#if (defined(OPENSSL_ALL) || defined(OPENSSL_EXTRA)) && !defined(NO_BIO)
#if defined(OPENSSL_ALL) && !defined(NO_BIO) && defined(WOLFSSL_CERT_GEN)
WOLFSSL_X509* peer = wolfSSL_get_peer_certificate(ssl);
if (peer) {
WOLFSSL_BIO* bioOut = wolfSSL_BIO_new(wolfSSL_BIO_s_file());
@ -1557,7 +1557,7 @@ static void showPeerPEM(WOLFSSL* ssl)
wolfSSL_BIO_free(bioOut);
}
wolfSSL_FreeX509(peer);
#endif /* (OPENSSL_ALL || OPENSSL_EXTRA) && !NO_BIO */
#endif /* OPENSSL_ALL && WOLFSSL_CERT_GEN && !NO_BIO */
(void)ssl;
}