diff options
| author | Michael Vogt <michael.vogt@ubuntu.com> | 2005-11-17 23:34:31 +0000 |
|---|---|---|
| committer | Michael Vogt <michael.vogt@ubuntu.com> | 2005-11-17 23:34:31 +0000 |
| commit | 4da233eef44c921152daf224a043ab8e2181ef9f (patch) | |
| tree | 91a9e0b84a5b45ad2a5c5dee656272cb336b83d9 /apt | |
| parent | 31177397ed5cecec39abb76d4797ef0f3e7eee46 (diff) | |
| download | python-apt-4da233eef44c921152daf224a043ab8e2181ef9f.tar.gz | |
* fix a bug in the package.markUpgrade() code
Diffstat (limited to 'apt')
| -rw-r--r-- | apt/package.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apt/package.py b/apt/package.py index bf03f515..5642496a 100644 --- a/apt/package.py +++ b/apt/package.py @@ -19,8 +19,7 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 # USA -import apt_pkg, string -import random +import apt_pkg, string, sys, random class Package(object): """ This class represents a package in the cache @@ -271,9 +270,10 @@ class Package(object): def markUpgrade(self): """ mark a package for upgrade """ if self.isUpgradable: - self.MarkInstall() - # FIXME: we may want to throw a exception here - sys.stderr.write("MarkUpgrade() called on a non-upgrable pkg") + self.markInstall() + else: + # FIXME: we may want to throw a exception here + sys.stderr.write("MarkUpgrade() called on a non-upgrable pkg: '%s'\n" %self._pkg.Name) def commit(self, fprogress, iprogress): """ commit the changes, need a FetchProgress and InstallProgress |
