diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-02-04 14:47:41 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-02-17 19:43:18 +0100 |
commit | b902eab45a79fa656abdbde4501c1c02adaf140a (patch) | |
tree | a3657a3c6c8c526f67e40450150b4a618d744ba4 | |
parent | 79d86b844f084b884363396da4ebb561e7c42a73 (diff) | |
download | ffmpeg-b902eab45a79fa656abdbde4501c1c02adaf140a.tar.gz |
avformat/mpc8: Use uint64_t in *_get_v() to avoid undefined behavior
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 05e161952954acf247e0fd1fdef00559675c4d4d)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/mpc8.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/mpc8.c b/libavformat/mpc8.c index 589c2f79ae..1d78933a30 100644 --- a/libavformat/mpc8.c +++ b/libavformat/mpc8.c @@ -57,7 +57,7 @@ typedef struct { static inline int64_t bs_get_v(const uint8_t **bs) { - int64_t v = 0; + uint64_t v = 0; int br = 0; int c; @@ -108,7 +108,7 @@ static int mpc8_probe(AVProbeData *p) static inline int64_t gb_get_v(GetBitContext *gb) { - int64_t v = 0; + uint64_t v = 0; int bits = 0; while(get_bits1(gb) && bits < 64-7){ v <<= 7; |