aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/electronicarts.c
diff options
context:
space:
mode:
authorAurelien Jacobs <aurel@gnuage.org>2007-10-18 23:42:54 +0000
committerAurelien Jacobs <aurel@gnuage.org>2007-10-18 23:42:54 +0000
commitc611463fe4f436ca22150cd8cbd7ed1ec7bc466e (patch)
tree3133243687adbc10ab2943db49b96332f8c49135 /libavformat/electronicarts.c
parent200f41ad2ecf3d5dbc017c16be4d7ef35fdc7de7 (diff)
downloadffmpeg-c611463fe4f436ca22150cd8cbd7ed1ec7bc466e.tar.gz
check if we found an audio track before initializing the audio stream
Originally committed as revision 10804 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/electronicarts.c')
-rw-r--r--libavformat/electronicarts.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/electronicarts.c b/libavformat/electronicarts.c
index fadf2fbaa4..3d69a5681a 100644
--- a/libavformat/electronicarts.c
+++ b/libavformat/electronicarts.c
@@ -257,6 +257,7 @@ static int ea_read_header(AVFormatContext *s,
st->codec->time_base = ea->time_base;
}
+ if (ea->audio_codec) {
/* initialize the audio decoder stream */
st = av_new_stream(s, 0);
if (!st)
@@ -274,6 +275,7 @@ static int ea_read_header(AVFormatContext *s,
ea->audio_stream_index = st->index;
ea->audio_frame_counter = 0;
+ }
return 1;
}