summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-02-08 12:51:52 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-02-08 12:51:52 +0100
commit47335126c049a5d2468b1b8b328c286a0d978159 (patch)
tree3fff802376961ba78c6535ace7a18af23677d41b
parent810cd0dd9c0350b2a108a73a8ec2f4f1919c4a27 (diff)
downloadffmpeg-streaming-47335126c049a5d2468b1b8b328c286a0d978159.zip
ffmpeg-streaming-47335126c049a5d2468b1b8b328c286a0d978159.tar.gz
ff_end_tag: assert that the start is aligned.
If its start is not aligned then aligning its end will likely break many demuxers as they check the size and not the position. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavformat/riff.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/riff.c b/libavformat/riff.c
index 352bb56..ac1a4ff 100644
--- a/libavformat/riff.c
+++ b/libavformat/riff.c
@@ -427,6 +427,8 @@ void ff_end_tag(AVIOContext *pb, int64_t start)
{
int64_t pos;
+ av_assert0((start&1) == 0);
+
pos = avio_tell(pb);
if (pos & 1)
avio_w8(pb, 0);
OpenPOWER on IntegriCloud