Skip to content

Commit 0ac6ca3

Browse files
committed
Fix hard tabs and c++ style comments
1 parent 761f0f1 commit 0ac6ca3

2 files changed

Lines changed: 12 additions & 10 deletions

File tree

tests/api.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68271,8 +68271,8 @@ TEST_CASE testCases[] = {
6827168271
TEST_DECL(test_ocsp_certid_enc_dec),
6827268272
TEST_DECL(test_tls12_unexpected_ccs),
6827368273
TEST_DECL(test_tls13_unexpected_ccs),
68274-
TEST_DECL(test_tls12_curve_intersection),
68275-
TEST_DECL(test_tls13_curve_intersection),
68274+
TEST_DECL(test_tls12_curve_intersection),
68275+
TEST_DECL(test_tls13_curve_intersection),
6827668276
TEST_DECL(test_wc_DhSetNamedKey),
6827768277
/* This test needs to stay at the end to clean up any caches allocated. */
6827868278
TEST_DECL(test_wolfSSL_Cleanup)

tests/api/test_tls.c

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -151,20 +151,22 @@ int test_tls12_curve_intersection(void) {
151151
struct test_memio_ctx test_ctx;
152152
int ret;
153153
const char* curve_name;
154-
int test1[] = {WOLFSSL_ECC_SECP256R1};
155-
int test2[] = {WOLFSSL_ECC_SECP384R1};
156-
int test3[] = {WOLFSSL_ECC_SECP256R1, WOLFSSL_ECC_SECP384R1};
157-
int test4[] = {WOLFSSL_ECC_SECP384R1, WOLFSSL_ECC_SECP256R1};
154+
int test1[] = {WOLFSSL_ECC_SECP256R1};
155+
int test2[] = {WOLFSSL_ECC_SECP384R1};
156+
int test3[] = {WOLFSSL_ECC_SECP256R1, WOLFSSL_ECC_SECP384R1};
157+
int test4[] = {WOLFSSL_ECC_SECP384R1, WOLFSSL_ECC_SECP256R1};
158158
XMEMSET(&test_ctx, 0, sizeof(test_ctx));
159159
ExpectIntEQ(test_memio_setup(&test_ctx, &ctx_c, &ctx_s, &ssl_c, &ssl_s,
160160
wolfTLSv1_2_client_method, wolfTLSv1_2_server_method), 0);
161161
ExpectIntEQ(wolfSSL_set_groups(ssl_c,
162162
test1, 1), WOLFSSL_SUCCESS);
163163
ExpectIntEQ(test_memio_do_handshake(ssl_c, ssl_s, 10, NULL), 0);
164164

165-
// Fix: Get curve name and compare with string comparison or use curve ID function
165+
/* Fix: Get curve name and compare with string comparison or use curve
166+
* ID function */
166167
curve_name = wolfSSL_get_curve_name(ssl_s);
167-
ExpectStrEQ(curve_name, "SECP256R1"); // or use appropriate string comparison
168+
/* or use appropriate string comparison */
169+
ExpectStrEQ(curve_name, "SECP256R1");
168170
curve_name = wolfSSL_get_curve_name(ssl_c);
169171
ExpectStrEQ(curve_name, "SECP256R1");
170172

@@ -187,7 +189,7 @@ int test_tls12_curve_intersection(void) {
187189
ExpectIntNE(test_memio_do_handshake(ssl_c, ssl_s, 10, NULL), 0);
188190
ret = wolfSSL_get_error(ssl_s, WOLFSSL_FATAL_ERROR);
189191

190-
// Fix: Use proper constant or define HANDSHAKE_FAILURE
192+
/* Fix: Use proper constant or define HANDSHAKE_FAILURE */
191193
ExpectTrue(ret == WC_NO_ERR_TRACE(ECC_CURVE_ERROR));
192194

193195
wolfSSL_free(ssl_c);
@@ -231,7 +233,7 @@ int test_tls13_curve_intersection(void) {
231233
WOLFSSL *ssl_c = NULL, *ssl_s = NULL;
232234
struct test_memio_ctx test_ctx;
233235
const char* curve_name;
234-
int test1[] ={WOLFSSL_ECC_SECP256R1};
236+
int test1[] ={WOLFSSL_ECC_SECP256R1};
235237

236238
XMEMSET(&test_ctx, 0, sizeof(test_ctx));
237239
ExpectIntEQ(test_memio_setup(&test_ctx, &ctx_c, &ctx_s, &ssl_c, &ssl_s,

0 commit comments

Comments
 (0)