diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-12-23 23:59:10 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-12-23 23:59:10 +0100 |
commit | ad9e0ed170234bc6c5660f96752777965081163e (patch) | |
tree | 2607007b8a8038e0b2221a117a0ad0ee9c6a29d2 /libavformat/avio.c | |
parent | 320b8d6335548c473deef58f638665c82dda35b4 (diff) | |
download | ffmpeg-ad9e0ed170234bc6c5660f96752777965081163e.tar.gz |
avio: fix handling of , in urls
Fixes Ticket805
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/avio.c')
-rw-r--r-- | libavformat/avio.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/avio.c b/libavformat/avio.c index efe1c26683..67005e3eca 100644 --- a/libavformat/avio.c +++ b/libavformat/avio.c @@ -145,10 +145,11 @@ static int url_alloc_for_protocol (URLContext **puc, struct URLProtocol *up, if (up->priv_data_size) { uc->priv_data = av_mallocz(up->priv_data_size); if (up->priv_data_class) { + int proto_len= strlen(up->name); char *start = strchr(uc->filename, ','); *(const AVClass**)uc->priv_data = up->priv_data_class; av_opt_set_defaults(uc->priv_data); - if(start){ + if(!strncmp(up->name, uc->filename, proto_len) && uc->filename + proto_len == start){ int ret= 0; char *p= start; char sep= *++p; |