From c45efd79afab65803402b54604abfae16a610d4f Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Wed, 31 May 2023 18:26:27 -0500 Subject: [PATCH] api.c: fix 3 missed EXPECT_RESULT() == WOLFSSL_SUCCESSes to use the succincter EXPECT_SUCCESS(). --- tests/api.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/api.c b/tests/api.c index e992c6f5d..7b154a5f0 100644 --- a/tests/api.c +++ b/tests/api.c @@ -9276,7 +9276,7 @@ static int test_wolfSSL_SNI_GetFromBuffer(void) ExpectIntEQ(WOLFSSL_SUCCESS, wolfSSL_SNI_GetFromBuffer(buff, sizeof(buff), 0, result, &length)); - if (EXPECT_RESULT() == TEST_SUCCESS) + if (EXPECT_SUCCESS()) result[length] = 0; ExpectStrEQ("www.paypal.com", (const char*) result); @@ -9284,7 +9284,7 @@ static int test_wolfSSL_SNI_GetFromBuffer(void) ExpectIntEQ(WOLFSSL_SUCCESS, wolfSSL_SNI_GetFromBuffer(buff2, sizeof(buff2), 0, result, &length)); - if (EXPECT_RESULT() == TEST_SUCCESS) + if (EXPECT_SUCCESS()) result[length] = 0; ExpectStrEQ("api.textmate.org", (const char*) result); @@ -34871,7 +34871,7 @@ static int test_wc_KeyPemToDer(void) /* Test NULL for DER buffer to return needed DER buffer size */ ExpectIntGT(ret = wc_KeyPemToDer(cert_buf, cert_sz, NULL, 0, ""), 0); ExpectIntLE(ret, cert_sz); - if (EXPECT_RESULT() == TEST_SUCCESS) + if (EXPECT_SUCCESS()) cert_dersz = ret; ExpectNotNull(cert_der = (byte*)malloc(cert_dersz)); ExpectIntGE(ret = wc_KeyPemToDer(cert_buf, cert_sz, cert_der, cert_dersz,