[libdvbpsi-devel] dump_pids: fix error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror, -Wformat]
Michael Ira Krufky
git at videolan.org
Wed Apr 16 15:53:35 CEST 2014
libdvbpsi | branch: master | Michael Ira Krufky <mkrufky at linuxtv.org> | Tue Apr 15 20:26:25 2014 -0400| [7bafc5c79159ec2faffbc9dc1b700d8a3ef6f023] | committer: Michael Ira Krufky
dump_pids: fix error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
gcc -DHAVE_CONFIG_H -I. -I.. -g -O2 -Wall -Werror --std=gnu99 -D_GNU_SOURCE -Wpointer-arith -Wcast-align -Wcast-qual -Wstrict-prototypes -Wshadow -Waggregate-return -Wmissing-prototypes -Wnested-externs -Wsign-compare -DDVBPSI_DIST -MT dump_pids-dump_pids.o -MD -MP -MF .deps/dump_pids-dump_pids.Tpo -c -o dump_pids-dump_pids.o `test -f 'dump_pids.c' || echo './'`dump_pids.c
dump_pids.c:56:54: error: format specifies type 'long' but the argument has type 'int64_t' (aka 'long long') [-Werror,-Wformat]
printf("packet %ld, pid %u (0x%x), cc %d\n", n, pid, pid, cc );
~~~ ^
%lld
1 error generated.
make[3]: *** [dump_pids-dump_pids.o] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
Signed-off-by: Michael Ira Krufky <mkrufky at linuxtv.org>
> http://git.videolan.org/gitweb.cgi/libdvbpsi.git/?a=commit;h=7bafc5c79159ec2faffbc9dc1b700d8a3ef6f023
---
examples/dump_pids.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/examples/dump_pids.c b/examples/dump_pids.c
index 27252ee..e23598d 100644
--- a/examples/dump_pids.c
+++ b/examples/dump_pids.c
@@ -53,7 +53,7 @@ int main(int argc, char *argv[])
uint32_t pid = ts_getpid(&p[0]);
uint32_t cc = ts_getcc(&p[0]);
n++;
- printf("packet %ld, pid %u (0x%x), cc %d\n", n, pid, pid, cc );
+ printf("packet %"PRId64", pid %u (0x%x), cc %d\n", n, pid, pid, cc );
}
close(file);
More information about the libdvbpsi-devel
mailing list