From 52c8ac7b694cf7aca4a6f69d7e5c9323042b8057 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Fri, 16 Aug 2019 18:40:55 +0200 Subject: record: Improve overflow handling In case of a ring buffer overflow, the rtems_record_drain() will push the complete ring buffer content to the client. While the items are processed by the client, new items may overwrite some items being processed. The overwritten items can be detected in the following iteration once the next tail/head information is pushed to the client. --- testsuites/libtests/record02/init.c | 1 + 1 file changed, 1 insertion(+) (limited to 'testsuites/libtests/record02/init.c') diff --git a/testsuites/libtests/record02/init.c b/testsuites/libtests/record02/init.c index 5aeeb18cd9..f1c93f7df8 100644 --- a/testsuites/libtests/record02/init.c +++ b/testsuites/libtests/record02/init.c @@ -105,6 +105,7 @@ static void Init(rtems_task_argument arg) cs = rtems_record_client_run(&ctx->client, &header, sizeof(header)); rtems_test_assert(cs == RTEMS_RECORD_CLIENT_SUCCESS); rtems_record_drain(drain_visitor, ctx); + rtems_record_client_destroy(&ctx->client); TEST_END(); rtems_test_exit(0); -- cgit v1.2.3