[yum-commits] Branch 'yum-3_2_X' - yum/packages.py

Tim Lauridsen timlau at osuosl.org
Mon Mar 30 13:02:05 UTC 2009


 yum/packages.py |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 5c87a09b7c1db1868d247c950dadd9a6797f85a6
Author: Tim Lauridsen <timlau at fedoraproject.org>
Date:   Mon Mar 30 15:01:56 2009 +0200

    pylint: Access to member '_verify_local_pkg_cache' before its definition line 697

diff --git a/yum/packages.py b/yum/packages.py
index f9515b6..efcf1db 100644
--- a/yum/packages.py
+++ b/yum/packages.py
@@ -521,6 +521,7 @@ class YumAvailablePackage(PackageObject, RpmBase):
         self.repo = repo
         self.state = None
         self._loadedfiles = False
+        self._verify_local_pkg_cache = None
 
         if pkgdict != None:
             self.importFromDict(pkgdict)
@@ -676,7 +677,7 @@ class YumAvailablePackage(PackageObject, RpmBase):
             nst = os.stat(self.localPkg())
         except OSError, e:
             return False
-        if hasattr(self, "_verify_local_pkg_cache"):
+        if self._verify_local_pkg_cache:
             ost = self._verify_local_pkg_cache
             if (ost.st_ino   == nst.st_ino   and
                 ost.st_dev   == nst.st_dev   and


More information about the Yum-commits mailing list