[vlc-commits] vlc_uri_resolve: reject invalid input (fixes #17514)
Rémi Denis-Courmont
git at videolan.org
Sat Oct 15 12:38:01 CEST 2016
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Oct 15 13:36:09 2016 +0300| [85f37121501898bf23bfc3143b0767dd35f1c1b9] | committer: Rémi Denis-Courmont
vlc_uri_resolve: reject invalid input (fixes #17514)
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=85f37121501898bf23bfc3143b0767dd35f1c1b9
---
src/text/url.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/src/text/url.c b/src/text/url.c
index df16092..821b2b0 100644
--- a/src/text/url.c
+++ b/src/text/url.c
@@ -678,7 +678,11 @@ char *vlc_uri_resolve(const char *base, const char *ref)
vlc_url_t tgt_uri;
char *pathbuf = NULL, *ret = NULL;
- vlc_UrlParse(&rel_uri, ref);
+ if (vlc_UrlParse(&rel_uri, ref))
+ {
+ vlc_UrlClean(&rel_uri);
+ return NULL;
+ }
if (rel_uri.psz_protocol != NULL)
{ /* Short circuit in case of absolute URI */
More information about the vlc-commits
mailing list