summaryrefslogtreecommitdiff
path: root/apt/debfile.py
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2011-12-19 12:06:06 +0100
committerMichael Vogt <michael.vogt@ubuntu.com>2011-12-19 12:06:06 +0100
commit10ec8cd5b5614606b3db9fdc3d6e248984048f0e (patch)
treecc0dfc5a71023941c032d8fa7681224fe35e634b /apt/debfile.py
parentf841101c94f1b5892f042ecab2c0c74e9b947c8c (diff)
downloadpython-apt-10ec8cd5b5614606b3db9fdc3d6e248984048f0e.tar.gz
* apt/debfile.py:
- fix crash in dep multiarch handling
Diffstat (limited to 'apt/debfile.py')
-rw-r--r--apt/debfile.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/apt/debfile.py b/apt/debfile.py
index 160a4a72..cd027c71 100644
--- a/apt/debfile.py
+++ b/apt/debfile.py
@@ -94,7 +94,8 @@ class DebPackage(object):
return pkgname
elif self._cache.is_virtual_package(pkgname):
return pkgname
- elif self._cache[pkgname].candidate.architecture == "all":
+ elif (pkgname in self._cache and
+ self._cache[pkgname].candidate.architecture == "all"):
return pkgname
# now do the real multiarch checking
multiarch_pkgname = "%s:%s" % (pkgname, self._multiarch)