diff options
-rw-r--r-- | bitbake/lib/bb/fetch2/ssh.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch2/ssh.py b/bitbake/lib/bb/fetch2/ssh.py index 484453088f..8d082b38c1 100644 --- a/bitbake/lib/bb/fetch2/ssh.py +++ b/bitbake/lib/bb/fetch2/ssh.py | |||
@@ -32,6 +32,7 @@ IETF secsh internet draft: | |||
32 | 32 | ||
33 | import re, os | 33 | import re, os |
34 | from bb.fetch2 import check_network_access, FetchMethod, ParameterError, runfetchcmd | 34 | from bb.fetch2 import check_network_access, FetchMethod, ParameterError, runfetchcmd |
35 | import urllib | ||
35 | 36 | ||
36 | 37 | ||
37 | __pattern__ = re.compile(r''' | 38 | __pattern__ = re.compile(r''' |
@@ -70,6 +71,7 @@ class SSH(FetchMethod): | |||
70 | "git:// prefix with protocol=ssh", urldata.url) | 71 | "git:// prefix with protocol=ssh", urldata.url) |
71 | m = __pattern__.match(urldata.url) | 72 | m = __pattern__.match(urldata.url) |
72 | path = m.group('path') | 73 | path = m.group('path') |
74 | path = urllib.parse.unquote(path) | ||
73 | host = m.group('host') | 75 | host = m.group('host') |
74 | urldata.localpath = os.path.join(d.getVar('DL_DIR'), | 76 | urldata.localpath = os.path.join(d.getVar('DL_DIR'), |
75 | os.path.basename(os.path.normpath(path))) | 77 | os.path.basename(os.path.normpath(path))) |
@@ -99,7 +101,7 @@ class SSH(FetchMethod): | |||
99 | 101 | ||
100 | if path[0] != '~': | 102 | if path[0] != '~': |
101 | path = '/%s' % path | 103 | path = '/%s' % path |
102 | path = path.replace("%3A", ":") | 104 | path = urllib.parse.unquote(path) |
103 | 105 | ||
104 | fr += ':%s' % path | 106 | fr += ':%s' % path |
105 | 107 | ||
@@ -139,7 +141,7 @@ class SSH(FetchMethod): | |||
139 | 141 | ||
140 | if path[0] != '~': | 142 | if path[0] != '~': |
141 | path = '/%s' % path | 143 | path = '/%s' % path |
142 | path = path.replace("%3A", ":") | 144 | path = urllib.parse.unquote(path) |
143 | 145 | ||
144 | cmd = 'ssh -o BatchMode=true %s %s [ -f %s ]' % ( | 146 | cmd = 'ssh -o BatchMode=true %s %s [ -f %s ]' % ( |
145 | portarg, | 147 | portarg, |