aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/concat.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-01-20 11:10:27 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2016-01-23 00:12:54 +0100
commit8e32d014322eada1812af268d7ea9d53169d279c (patch)
tree90b7cabe488320a9f5d57a0d899ad1b3ef45c132 /libavformat/concat.c
parent9a8034b8bc1d1cd7a8889dc385d41744be47b159 (diff)
downloadffmpeg-8e32d014322eada1812af268d7ea9d53169d279c.tar.gz
avformat/concat: Check protocol prefix
Reviewed-by: Andreas Cadhalpun <andreas.cadhalpun@googlemail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavformat/concat.c')
-rw-r--r--libavformat/concat.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libavformat/concat.c b/libavformat/concat.c
index 81fe97082c..7bcc27905e 100644
--- a/libavformat/concat.c
+++ b/libavformat/concat.c
@@ -65,7 +65,10 @@ static av_cold int concat_open(URLContext *h, const char *uri, int flags)
struct concat_data *data = h->priv_data;
struct concat_nodes *nodes;
- av_strstart(uri, "concat:", &uri);
+ if (!av_strstart(uri, "concat:", &uri)) {
+ av_log(h, AV_LOG_ERROR, "URL %s lacks prefix\n", uri);
+ return AVERROR(EINVAL);
+ }
for (i = 0, len = 1; uri[i]; i++) {
if (uri[i] == *AV_CAT_SEPARATOR) {