test-platform.c: write_packet(): use `const size_t`
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Thu, 24 Sep 2020 11:32:13 +0000 (07:32 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Thu, 24 Sep 2020 11:32:13 +0000 (07:32 -0400)
Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
tests/tracing/support/test-platform.c

index ac9559791a0d63e13b7c6d2794a138cbf69d53b5..9fd6d0ef0a2b460fc2643c16d5a4a82eb44a9f88 100644 (file)
@@ -36,9 +36,10 @@ struct test_platform_ctx {
 
 static void write_packet(struct test_platform_ctx * const platform_ctx)
 {
-       size_t nmemb = fwrite(barectf_packet_buf(&platform_ctx->ctx),
+       const size_t nmemb = fwrite(barectf_packet_buf(&platform_ctx->ctx),
                barectf_packet_buf_size(&platform_ctx->ctx), 1,
                        platform_ctx->fh);
+
        assert(nmemb == 1);
 }
 
This page took 0.026447 seconds and 4 git commands to generate.