diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-04-07 15:42:45 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-04-07 15:42:45 +0200 |
commit | e9d5a6f1c5b65319400a45446ae6523a2296de73 (patch) | |
tree | 11110d207fd762b9c52233cde9aba0b32090d0b1 /libavcodec/atrac3.c | |
parent | 0af8ed29e4a756c3e207ac65f479c23ca8ed025b (diff) | |
parent | 327ff82bac3081d918dceb4931c77e25d0a1480d (diff) | |
download | ffmpeg-e9d5a6f1c5b65319400a45446ae6523a2296de73.tar.gz |
Merge commit '327ff82bac3081d918dceb4931c77e25d0a1480d' into release/0.10
* commit '327ff82bac3081d918dceb4931c77e25d0a1480d':
msrle: convert MS RLE decoding function to bytestream2.
Update Changelog for the 0.8.6 Release
wmaprodec: require block_align to be set.
ivi_common: do not call MC for intra frames when dc_transform is unset
roqvideodec: fix a potential infinite loop in roqvideo_decode_frame().
Revert "libmp3lame: use the correct remaining buffer size when flushing"
lzo: fix overflow checking in copy_backptr()
flacdec: simplify bounds checking in flac_probe()
atrac3: avoid oversized shifting in decode_bytes()
avconv: skip attached files when selecting streams to read from.
lavf: fix arithmetic overflows in avformat_seek_file()
Conflicts:
Changelog
avconv.c
libavcodec/libmp3lame.c
libavcodec/msrledec.c
libavformat/utils.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/atrac3.c')
-rw-r--r-- | libavcodec/atrac3.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libavcodec/atrac3.c b/libavcodec/atrac3.c index df09ea1802..e88c7eefd9 100644 --- a/libavcodec/atrac3.c +++ b/libavcodec/atrac3.c @@ -184,8 +184,11 @@ static int decode_bytes(const uint8_t* inbuffer, uint8_t* out, int bytes){ uint32_t* obuf = (uint32_t*) out; off = (intptr_t)inbuffer & 3; - buf = (const uint32_t*) (inbuffer - off); - c = av_be2ne32((0x537F6103 >> (off*8)) | (0x537F6103 << (32-(off*8)))); + buf = (const uint32_t *)(inbuffer - off); + if (off) + c = av_be2ne32((0x537F6103U >> (off * 8)) | (0x537F6103U << (32 - (off * 8)))); + else + c = av_be2ne32(0x537F6103U); bytes += 3 + off; for (i = 0; i < bytes/4; i++) obuf[i] = c ^ buf[i]; |