diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-09-29 21:11:47 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-09-29 21:28:22 +0200 |
commit | 4be0c6ed20f214c8dbf640722f7d0e2d00c85325 (patch) | |
tree | fcf38ee10489be333bf81f1f88c6737ac97cbaf4 /libavcodec | |
parent | 61274193e3bf842988ce550c312f984916dc9c7d (diff) | |
download | ffmpeg-4be0c6ed20f214c8dbf640722f7d0e2d00c85325.tar.gz |
avcodec/tiff_common: fix bprint max sizes
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/tiff_common.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/tiff_common.c b/libavcodec/tiff_common.c index 130093547e..f051022952 100644 --- a/libavcodec/tiff_common.c +++ b/libavcodec/tiff_common.c @@ -90,7 +90,7 @@ int ff_tadd_rational_metadata(int count, const char *name, const char *sep, return AVERROR_INVALIDDATA; if (!sep) sep = ", "; - av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_AUTOMATIC); + av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED); for (i = 0; i < count; i++) { nom = ff_tget_long(gb, le); @@ -124,7 +124,7 @@ int ff_tadd_long_metadata(int count, const char *name, const char *sep, return AVERROR_INVALIDDATA; if (!sep) sep = ", "; - av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_AUTOMATIC); + av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED); for (i = 0; i < count; i++) { av_bprintf(&bp, "%s%i", (i ? sep : ""), ff_tget_long(gb, le)); @@ -156,7 +156,7 @@ int ff_tadd_doubles_metadata(int count, const char *name, const char *sep, return AVERROR_INVALIDDATA; if (!sep) sep = ", "; - av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_AUTOMATIC); + av_bprint_init(&bp, 10 * count, 100 * count); for (i = 0; i < count; i++) { av_bprintf(&bp, "%s%f", (i ? sep : ""), ff_tget_double(gb, le)); @@ -188,7 +188,7 @@ int ff_tadd_shorts_metadata(int count, const char *name, const char *sep, return AVERROR_INVALIDDATA; if (!sep) sep = ", "; - av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_AUTOMATIC); + av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED); for (i = 0; i < count; i++) { av_bprintf(&bp, "%s%i", (i ? sep : ""), ff_tget_short(gb, le)); @@ -220,7 +220,7 @@ int ff_tadd_bytes_metadata(int count, const char *name, const char *sep, return AVERROR_INVALIDDATA; if (!sep) sep = ", "; - av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_AUTOMATIC); + av_bprint_init(&bp, 10 * count, AV_BPRINT_SIZE_UNLIMITED); for (i = 0; i < count; i++) { av_bprintf(&bp, "%s%i", (i ? sep : ""), bytestream2_get_byte(gb)); |