diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index e4db145d94..35344fbadc 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -3960,9 +3960,9 @@ static int webm_dash_manifest_read_header(AVFormatContext *s) av_log(s, AV_LOG_ERROR, "Failed to read file headers\n"); return -1; } - if (!s->nb_streams) { + if (!matroska->tracks.nb_elem || !s->nb_streams) { matroska_read_close(s); - av_log(s, AV_LOG_ERROR, "No streams found\n"); + av_log(s, AV_LOG_ERROR, "No track found\n"); return AVERROR_INVALIDDATA; }