Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-07-07 01:53:19 +0400
committerJames Almer <jamrial@gmail.com>2013-07-08 04:42:01 +0400
commitba4cb43f0b94ad7a468d34c172a87c73c95243a7 (patch)
treebd73e3585d54cf7d9fd0ff1a24125e7023dde966 /libavformat
parentdc73774792265e24fc1aad1b9d36f7c6669b8d66 (diff)
oggparseskeleton: avoid header parsing failure
Based on description by James Almer and the xiph wiki Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit 9a6e814be7c052deb34a8f585176d053f4c187c1)
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/oggparseskeleton.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/oggparseskeleton.c b/libavformat/oggparseskeleton.c
index b0121059a0..d94b0c2e07 100644
--- a/libavformat/oggparseskeleton.c
+++ b/libavformat/oggparseskeleton.c
@@ -37,6 +37,9 @@ static int skeleton_header(AVFormatContext *s, int idx)
strcpy(st->codec->codec_name, "skeleton");
st->codec->codec_type = AVMEDIA_TYPE_DATA;
+ if ((os->flags & OGG_FLAG_EOS) && os->psize == 0)
+ return 1;
+
if (os->psize < 8)
return -1;