diff options
author | AlexDenisov <1101.debian@gmail.com> | 2017-10-28 13:17:06 +0200 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2017-10-30 11:36:29 -0400 |
commit | 23fa978994b52ac60c1fcbe1e094d65d7c78c7bb (patch) | |
tree | f34a48a70eda7f720d5b17c28b605602673d2390 /test/packettest.c | |
parent | 3be08e301146fc449315b7061d086edddb186850 (diff) | |
download | openssl-23fa978994b52ac60c1fcbe1e094d65d7c78c7bb.tar.gz |
[packettest] Fix misplaced parentheses
Thanks to David Benjamin for suggesting the fix needed by this fix.
CLA: trivial
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/4607)
Diffstat (limited to 'test/packettest.c')
-rw-r--r-- | test/packettest.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/packettest.c b/test/packettest.c index 83d1ccd3bb..98b9ec4889 100644 --- a/test/packettest.c +++ b/test/packettest.c @@ -18,12 +18,12 @@ static int test_PACKET_remaining(void) { PACKET pkt; - if (!TEST_true(PACKET_buf_init(&pkt, smbuf, sizeof(smbuf)) + if (!TEST_true(PACKET_buf_init(&pkt, smbuf, sizeof(smbuf))) || !TEST_size_t_eq(PACKET_remaining(&pkt), BUF_LEN) || !TEST_true(PACKET_forward(&pkt, BUF_LEN - 1)) || !TEST_size_t_eq(PACKET_remaining(&pkt), 1) || !TEST_true(PACKET_forward(&pkt, 1)) - || !TEST_size_t_eq(PACKET_remaining(&pkt), 0))) + || !TEST_size_t_eq(PACKET_remaining(&pkt), 0)) return 0; return 1; @@ -33,13 +33,13 @@ static int test_PACKET_end(void) { PACKET pkt; - if (!TEST_true(PACKET_buf_init(&pkt, smbuf, sizeof(smbuf)) + if (!TEST_true(PACKET_buf_init(&pkt, smbuf, sizeof(smbuf))) || !TEST_size_t_eq(PACKET_remaining(&pkt), BUF_LEN) - || !TEST_ptr_ne(PACKET_end(&pkt), smbuf + BUF_LEN) + || !TEST_ptr_eq(PACKET_end(&pkt), smbuf + BUF_LEN) || !TEST_true(PACKET_forward(&pkt, BUF_LEN - 1)) || !TEST_ptr_eq(PACKET_end(&pkt), smbuf + BUF_LEN) || !TEST_true(PACKET_forward(&pkt, 1)) - || !TEST_ptr_eq(PACKET_end(&pkt), smbuf + BUF_LEN))) + || !TEST_ptr_eq(PACKET_end(&pkt), smbuf + BUF_LEN)) return 0; return 1; @@ -430,9 +430,9 @@ static int test_PACKET_as_length_prefixed_1(void) || !TEST_true(PACKET_buf_init(&exact_pkt, buf1, len + 1)) || !TEST_false(PACKET_as_length_prefixed_1(&pkt, &subpkt)) || !TEST_size_t_eq(PACKET_remaining(&pkt), BUF_LEN) - || !TEST_true(PACKET_as_length_prefixed_1(&exact_pkt, &subpkt) + || !TEST_true(PACKET_as_length_prefixed_1(&exact_pkt, &subpkt)) || !TEST_size_t_eq(PACKET_remaining(&exact_pkt), 0) - || !TEST_size_t_eq(PACKET_remaining(&subpkt), len))) + || !TEST_size_t_eq(PACKET_remaining(&subpkt), len)) return 0; return 1; |