From: Jaroslav Kysela Date: Thu, 7 Dec 2017 14:00:20 +0000 (+0100) Subject: url: another fix for urlrecompose (empty auth) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=00d473a2d5c27cedc49e99a2ee7b0156a6e6ad29;p=thirdparty%2Ftvheadend.git url: another fix for urlrecompose (empty auth) --- diff --git a/src/url.c b/src/url.c index aadbee1d0..b742b3b7e 100644 --- a/src/url.c +++ b/src/url.c @@ -59,7 +59,8 @@ urlrecompose( url_t *url ) { size_t len; char *raw, port[16]; - const int auth = url->user && url->pass; + const int auth = url->user && url->user[0] && + url->pass && url->pass[0]; len = (url->scheme ? strlen(url->scheme) : 0) + 4 + (auth ? (strlen(url->user) + strlen(url->pass) + 2) : 0) +