apetag: Fix APE tag size check
authorKaterina Barone-Adesi <katerinab@gmail.com>
Mon, 15 Sep 2014 23:40:24 +0000 (01:40 +0200)
committerDiego Biurrun <diego@biurrun.de>
Wed, 17 Sep 2014 14:50:55 +0000 (07:50 -0700)
commitb989bb7adee0f3286dcaa63c5cd0753eac45f6be
tree8bc0153d43301bad03a4b44ff6ba39679be93706
parent893b353362bc220280efd8d14c4878a1cafe18a8
apetag: Fix APE tag size check

The size variable is (correctly) unsigned, but is passed to several functions
which take signed parameters, such as avio_read, sometimes after having
numbers added to it. So ensure that size remains within the bounds that
these functions can handle.

(cherry picked from commit 56ac2cbd0464e0146e62c91843e2b1f5e0908504)
Signed-off-by: Diego Biurrun <diego@biurrun.de>
Conflicts:
libavformat/apetag.c
libavformat/apetag.c