aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-07-21 01:17:36 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-07-21 01:17:41 +0200
commitb8b73739141eadcd6a685c8c5d69cfb59c5530df (patch)
tree11d580ff7638debe20058e7589e815fd0359b3e2 /libavformat
parentd46713cc7e7dfd88b813078a71ed1c29e42011ca (diff)
parentbe23cee317f52f3dffa49812f412c0041d8b0de3 (diff)
downloadffmpeg-b8b73739141eadcd6a685c8c5d69cfb59c5530df.tar.gz
Merge remote-tracking branch 'jamrial/release/1.0' into release/1.0
* jamrial/release/1.0: oggparseskeleton: avoid header parsing failure oggparseskeleton: Replace avpriv_report_missing_feature() with a normal av_log() call oggparseskeleton: Fix fisbone header parsing Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/oggparseskeleton.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/libavformat/oggparseskeleton.c b/libavformat/oggparseskeleton.c
index 4b02c838f2..79c018da66 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;
@@ -74,12 +77,16 @@ static int skeleton_header(AVFormatContext *s, int idx)
target_idx = ogg_find_stream(ogg, AV_RL32(buf+12));
start_granule = AV_RL64(buf+36);
+ if (target_idx < 0) {
+ av_log(s, AV_LOG_WARNING, "Serial number in fisbone doesn't match any stream\n");
+ return 1;
+ }
+ os = ogg->streams + target_idx;
if (os->start_granule != OGG_NOGRANULE_VALUE) {
- av_log_missing_feature(s, "multiple fisbone for the "
- "same stream\n", 0);
+ av_log(s, AV_LOG_WARNING, "Multiple fisbone for the same stream\n");
return 1;
}
- if (target_idx >= 0 && start_granule != OGG_NOGRANULE_VALUE) {
+ if (start_granule != OGG_NOGRANULE_VALUE) {
os->start_granule = start_granule;
}
}