[FFmpeg-cvslog] bprint-test: avoid z modifier, mingw fails with it

Michael Niedermayer git at videolan.org
Sun Jun 10 03:53:40 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sun Jun 10 03:49:31 2012 +0200| [4bfee465e99cb3ef5da4db04e7eec4e5f2fec0cc] | committer: Michael Niedermayer

bprint-test: avoid z modifier, mingw fails with it

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4bfee465e99cb3ef5da4db04e7eec4e5f2fec0cc
---

 libavutil/bprint.c |   14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/libavutil/bprint.c b/libavutil/bprint.c
index 75344f7..f9d5d6a 100644
--- a/libavutil/bprint.c
+++ b/libavutil/bprint.c
@@ -191,36 +191,36 @@ int main(void)
 
     av_bprint_init(&b, 0, -1);
     bprint_pascal(&b, 5);
-    printf("Short text in unlimited buffer: %zu/%u\n", strlen(b.str), b.len);
+    printf("Short text in unlimited buffer: %u/%u\n", (unsigned)strlen(b.str), b.len);
     printf("%s\n", b.str);
     av_bprint_finalize(&b, NULL);
 
     av_bprint_init(&b, 0, -1);
     bprint_pascal(&b, 25);
-    printf("Long text in unlimited buffer: %zu/%u\n", strlen(b.str), b.len);
+    printf("Long text in unlimited buffer: %u/%u\n", (unsigned)strlen(b.str), b.len);
     av_bprint_finalize(&b, NULL);
 
     av_bprint_init(&b, 0, 2048);
     bprint_pascal(&b, 25);
-    printf("Long text in limited buffer: %zu/%u\n", strlen(b.str), b.len);
+    printf("Long text in limited buffer: %u/%u\n", (unsigned)strlen(b.str), b.len);
     av_bprint_finalize(&b, NULL);
 
     av_bprint_init(&b, 0, 1);
     bprint_pascal(&b, 5);
-    printf("Short text in automatic buffer: %zu/%u\n", strlen(b.str), b.len);
+    printf("Short text in automatic buffer: %u/%u\n", (unsigned)strlen(b.str), b.len);
 
     av_bprint_init(&b, 0, 1);
     bprint_pascal(&b, 25);
-    printf("Long text in automatic buffer: %zu/%u\n", strlen(b.str)/8*8, b.len);
+    printf("Long text in automatic buffer: %u/%u\n", (unsigned)strlen(b.str)/8*8, b.len);
     /* Note that the size of the automatic buffer is arch-dependant. */
 
     av_bprint_init(&b, 0, 0);
     bprint_pascal(&b, 25);
-    printf("Long text count only buffer: %zu/%u\n", strlen(b.str), b.len);
+    printf("Long text count only buffer: %u/%u\n", (unsigned)strlen(b.str), b.len);
 
     av_bprint_init_for_buffer(&b, buf, sizeof(buf));
     bprint_pascal(&b, 25);
-    printf("Long text count only buffer: %zu/%u\n", strlen(buf), b.len);
+    printf("Long text count only buffer: %u/%u\n", (unsigned)strlen(buf), b.len);
 
     return 0;
 }



More information about the ffmpeg-cvslog mailing list