avformat/dashdec: Fail with any inner stream count being 0
Fixes: ada-3-poc.mpd
Found-by: Claude and Ada Logics. This issue was found by Anthropic from using agents to study security of open source projects, and I am from Ada Logics helping validate the found issues and report to maintainers.
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit b99c6fc8c3)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -2101,6 +2101,8 @@ static int dash_read_header(AVFormatContext *s)
|
||||
|
||||
if (ret)
|
||||
return ret;
|
||||
if (rep->ctx->nb_streams == 0)
|
||||
return AVERROR_PATCHWELCOME;
|
||||
rep->stream_index = stream_index;
|
||||
++stream_index;
|
||||
}
|
||||
@@ -2119,6 +2121,8 @@ static int dash_read_header(AVFormatContext *s)
|
||||
|
||||
if (ret)
|
||||
return ret;
|
||||
if (rep->ctx->nb_streams == 0)
|
||||
return AVERROR_PATCHWELCOME;
|
||||
rep->stream_index = stream_index;
|
||||
++stream_index;
|
||||
}
|
||||
@@ -2137,6 +2141,8 @@ static int dash_read_header(AVFormatContext *s)
|
||||
|
||||
if (ret)
|
||||
return ret;
|
||||
if (rep->ctx->nb_streams == 0)
|
||||
return AVERROR_PATCHWELCOME;
|
||||
rep->stream_index = stream_index;
|
||||
++stream_index;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user