From 6a12a5740b338437cc39480452c1282d0298325d Mon Sep 17 00:00:00 2001 From: Emilia Kasper Date: Thu, 17 Sep 2015 21:28:07 +0200 Subject: PACKET: simplify Get rid of the third field that is no longer needed. Reviewed-by: Rich Salz --- test/packettest.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'test/packettest.c') diff --git a/test/packettest.c b/test/packettest.c index fcae19fe6d..6ee2ab15a6 100644 --- a/test/packettest.c +++ b/test/packettest.c @@ -312,20 +312,13 @@ static int test_PACKET_forward(unsigned char buf[BUF_LEN]) static int test_PACKET_buf_init() { unsigned char buf[BUF_LEN]; - size_t len; PACKET pkt; /* Also tests PACKET_get_len() */ if ( !PACKET_buf_init(&pkt, buf, 4) - || !PACKET_length(&pkt, &len) - || len != 4 + || PACKET_remaining(&pkt) != 4 || !PACKET_buf_init(&pkt, buf, BUF_LEN) - || !PACKET_length(&pkt, &len) - || len != BUF_LEN - || pkt.end - pkt.start != BUF_LEN - || pkt.end < pkt.start - || pkt.curr < pkt.start - || pkt.curr > pkt.end + || PACKET_remaining(&pkt) != BUF_LEN || PACKET_buf_init(&pkt, buf, -1)) { fprintf(stderr, "test_PACKET_buf_init() failed\n"); return 0; -- cgit v1.2.3