From 88ad6d975e5965b54b97fced8323a55c39d8a9f1 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Thu, 30 Mar 2017 11:42:59 +0100 Subject: bitbake: wget: Fix handling of urls with user/password URL decoding was improved in the core a while ago and this looks like a leftover from those times which caused urls needing a user/password to fail. Use the parameters from the core instead of the broken split implementation. [YOCTO #11262] (Bitbake rev: 32a249cf33f79b579a2cf6224c7d23cdb20d376f) Signed-off-by: Richard Purdie --- bitbake/lib/bb/fetch2/wget.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'bitbake/lib/bb/fetch2') diff --git a/bitbake/lib/bb/fetch2/wget.py b/bitbake/lib/bb/fetch2/wget.py index ecb946aa81..23d48acb07 100644 --- a/bitbake/lib/bb/fetch2/wget.py +++ b/bitbake/lib/bb/fetch2/wget.py @@ -108,9 +108,8 @@ class Wget(FetchMethod): bb.utils.mkdirhier(os.path.dirname(dldir + os.sep + ud.localfile)) fetchcmd += " -O " + dldir + os.sep + ud.localfile - if ud.user: - up = ud.user.split(":") - fetchcmd += " --user=%s --password=%s --auth-no-challenge" % (up[0],up[1]) + if ud.user and ud.pswd: + fetchcmd += " --user=%s --password=%s --auth-no-challenge" % (ud.user, ud.pswd) uri = ud.url.split(";")[0] if os.path.exists(ud.localpath): -- cgit v1.2.3-54-g00ecf