aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/audiointerleave.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-04-01 21:21:13 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-04-01 21:21:13 +0200
commitb3ab337227ec78ba2de24b1f1972e116257e9ebb (patch)
treec13588a5ef6419d624c2377376723200797ca4e9 /libavformat/audiointerleave.c
parentce9bd303794fcc94aa232c116bece13c5994b55b (diff)
downloadffmpeg-b3ab337227ec78ba2de24b1f1972e116257e9ebb.tar.gz
audiointerleave: check timebase
Replaces FPE by clean error Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/audiointerleave.c')
-rw-r--r--libavformat/audiointerleave.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libavformat/audiointerleave.c b/libavformat/audiointerleave.c
index 922f4a5880..609a5117a3 100644
--- a/libavformat/audiointerleave.c
+++ b/libavformat/audiointerleave.c
@@ -47,6 +47,10 @@ int ff_audio_interleave_init(AVFormatContext *s,
if (!samples_per_frame)
return -1;
+ if (!time_base.num) {
+ av_log(s, AV_LOG_ERROR, "timebase not set for audio interleave\n");
+ return -1;
+ }
for (i = 0; i < s->nb_streams; i++) {
AVStream *st = s->streams[i];
AudioInterleaveContext *aic = st->priv_data;