[Yum-devel] [PATCH] for rh bug 604529 - make sure when we compare mtime we're comparing the ints vs the ints and not extra trailing fractions of a second.

Seth Vidal skvidal at fedoraproject.org
Thu Jun 17 18:30:16 UTC 2010


---
 yum/packages.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/yum/packages.py b/yum/packages.py
index 14015fd..8d572bf 100644
--- a/yum/packages.py
+++ b/yum/packages.py
@@ -1588,11 +1588,11 @@ class YumInstalledPackage(YumHeaderPackage):
                     check_perms = False
 
                 if (check_content and vflags & _RPMVERIFY_MTIME and
-                    my_st.st_mtime != mtime):
+                    int(my_st.st_mtime) != int(mtime)):
                     prob = _PkgVerifyProb('mtime', 'mtime does not match',
                                           ftypes)
                     prob.database_value = mtime
-                    prob.disk_value     = my_st.st_mtime
+                    prob.disk_value     = int(my_st.st_mtime)
                     problems.append(prob)
 
                 if check_perms and vflags & _RPMVERIFY_USER and my_user != user:
-- 
1.7.0.1



More information about the Yum-devel mailing list