1 |
commit: 528dc7cfa2856c1467759e81c99e35322fbffcce |
2 |
Author: Arfrever Frehtes Taifersar Arahesis <Arfrever <AT> Apache <DOT> Org> |
3 |
AuthorDate: Tue Dec 1 17:54:17 2015 +0000 |
4 |
Commit: Arfrever Frehtes Taifersar Arahesis <arfrever <AT> apache <DOT> org> |
5 |
CommitDate: Tue Dec 1 17:54:17 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=528dc7cf |
7 |
|
8 |
portage.package.ebuild.fetch.fetch(): Clean setting of variables. |
9 |
|
10 |
pym/portage/package/ebuild/fetch.py | 9 ++++----- |
11 |
1 file changed, 4 insertions(+), 5 deletions(-) |
12 |
|
13 |
diff --git a/pym/portage/package/ebuild/fetch.py b/pym/portage/package/ebuild/fetch.py |
14 |
index 7e4e6fe..1be2800 100644 |
15 |
--- a/pym/portage/package/ebuild/fetch.py |
16 |
+++ b/pym/portage/package/ebuild/fetch.py |
17 |
@@ -1,4 +1,4 @@ |
18 |
-# Copyright 2010-2014 Gentoo Foundation |
19 |
+# Copyright 2010-2015 Gentoo Foundation |
20 |
# Distributed under the terms of the GNU General Public License v2 |
21 |
|
22 |
from __future__ import print_function |
23 |
@@ -987,10 +987,9 @@ def fetch(myuris, mysettings, listonly=0, fetchonly=0, |
24 |
} |
25 |
|
26 |
for k in ("DISTDIR", "PORTAGE_SSH_OPTS"): |
27 |
- try: |
28 |
- variables[k] = mysettings[k] |
29 |
- except KeyError: |
30 |
- pass |
31 |
+ v = mysettings.get(k) |
32 |
+ if v is not None: |
33 |
+ variables[k] = v |
34 |
|
35 |
myfetch = shlex_split(locfetch) |
36 |
myfetch = [varexpand(x, mydict=variables) for x in myfetch] |