From de8fae7119c3e6d41f2dc79b3573c2eabcf2072b Mon Sep 17 00:00:00 2001 From: shizhenghui Date: Wed, 9 Oct 2024 10:25:06 +0800 Subject: [PATCH] nxcodec: fix build warning MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit nxcodec_main.c:143:37: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 2 has type ‘uint32_t’ {aka ‘unsigned int’} [-Wformat=] 143 | printf("nxcodec size: %lux%lu\n", | ~~^ | | | long unsigned int | %u 144 | codec.output.format.fmt.pix.width, | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | uint32_t {aka unsigned int} nxcodec_main.c:143:41: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘uint32_t’ {aka ‘unsigned int’} [-Wformat=] 143 | printf("nxcodec size: %lux%lu\n", | ~~^ | | | long unsigned int | %u 144 | codec.output.format.fmt.pix.width, 145 | codec.output.format.fmt.pix.height); | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | | | uint32_t {aka unsigned int} Signed-off-by: shizhenghui --- system/nxcodec/nxcodec_main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/system/nxcodec/nxcodec_main.c b/system/nxcodec/nxcodec_main.c index 39cc5308d..06f9f910c 100644 --- a/system/nxcodec/nxcodec_main.c +++ b/system/nxcodec/nxcodec_main.c @@ -140,7 +140,7 @@ int main(int argc, FAR char **argv) codec.capture.format.fmt.pix.width; codec.output.format.fmt.pix.height = codec.capture.format.fmt.pix.height; - printf("nxcodec size: %lux%lu\n", + printf("nxcodec size: %"PRIu32"x%"PRIu32"\n", codec.output.format.fmt.pix.width, codec.output.format.fmt.pix.height);