aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/matroskadec.c
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2017-03-16 17:20:47 -0400
committerVittorio Giovara <vittorio.giovara@gmail.com>2017-03-17 13:12:25 -0400
commitf20bcec4c2b1c2a57ed89e5be1ac2e0db1bc62b4 (patch)
treef5fb98454708d907841bdb59383a259d139e75dd /libavformat/matroskadec.c
parent21a8e751ad6abb2d423afa3041da92f8f7741997 (diff)
downloadffmpeg-f20bcec4c2b1c2a57ed89e5be1ac2e0db1bc62b4.tar.gz
spherical: Change types of bounding and pad to uint32_t
These values are defined to be 32bit in the specification, so it makes more sense to store them as fixed width. Based on a patch by Micahel Niedermayer <michael@niedermayer.cc>. Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavformat/matroskadec.c')
-rw-r--r--libavformat/matroskadec.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c
index fdb23ab05e..bad034b770 100644
--- a/libavformat/matroskadec.c
+++ b/libavformat/matroskadec.c
@@ -1913,8 +1913,8 @@ static int mkv_parse_video_projection(AVStream *st, const MatroskaTrack *track)
AVSphericalMapping *spherical;
enum AVSphericalProjection projection;
size_t spherical_size;
- size_t l = 0, t = 0, r = 0, b = 0;
- size_t padding = 0;
+ uint32_t l = 0, t = 0, r = 0, b = 0;
+ uint32_t padding = 0;
int ret;
GetByteContext gb;
@@ -1939,8 +1939,7 @@ static int mkv_parse_video_projection(AVStream *st, const MatroskaTrack *track)
if (b >= UINT_MAX - t || r >= UINT_MAX - l) {
av_log(NULL, AV_LOG_ERROR,
"Invalid bounding rectangle coordinates "
- "%"SIZE_SPECIFIER",%"SIZE_SPECIFIER","
- "%"SIZE_SPECIFIER",%"SIZE_SPECIFIER"\n",
+ "%"PRIu32",%"PRIu32",%"PRIu32",%"PRIu32"\n",
l, t, r, b);
return AVERROR_INVALIDDATA;
}