diff mbox series

[3/4] v4l-utils: use 64-bit off_t format

Message ID 20240702193343.5742-3-rosenp@gmail.com (mailing list archive)
State New
Headers show
Series [1/4] v4l-utils: fix formats under alpha/ppc64/mips64 | expand

Commit Message

Rosen Penev July 2, 2024, 7:33 p.m. UTC
musl uses 64-bit off_t by default on all platforms. Cast and fix format
to work everywhere.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
---
 utils/v4l2-tracer/retrace.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/utils/v4l2-tracer/retrace.cpp b/utils/v4l2-tracer/retrace.cpp
index 60d64d8b..010936c0 100644
--- a/utils/v4l2-tracer/retrace.cpp
+++ b/utils/v4l2-tracer/retrace.cpp
@@ -72,7 +72,7 @@  void retrace_mmap(json_object *mmap_obj, bool is_mmap64)
 	                           (long) buf_address_retrace_pointer);
 
 	if (is_verbose() || (errno != 0)) {
-		fprintf(stderr, "fd: %d, offset: %ld, ", fd_retrace, off);
+		fprintf(stderr, "fd: %d, offset: %lld, ", fd_retrace, (long long)off);
 		if (is_mmap64)
 			perror("mmap64");
 		else