aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2009-12-21 03:03:51 +0000
committerZac Medico <zmedico@gentoo.org>2009-12-21 03:03:51 +0000
commitd67fece1b741c0aae609436cd83ac0d2c448092c (patch)
tree60b4f0767576d86780dbcd93aa3095c82f6b7e62 /pym/portage/eclass_cache.py
parentRemove some old debug code that should not have been committed. (diff)
downloadportage-d67fece1b741c0aae609436cd83ac0d2c448092c.tar.gz
portage-d67fece1b741c0aae609436cd83ac0d2c448092c.tar.bz2
portage-d67fece1b741c0aae609436cd83ac0d2c448092c.zip
When integer mtime is desired, use stat_obj[stat.ST_MTIME] instead of the
float st_mtime in order to avoid rounding *up* in some rare cases. svn path=/main/trunk/; revision=15125
Diffstat (limited to 'pym/portage/eclass_cache.py')
-rw-r--r--pym/portage/eclass_cache.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/pym/portage/eclass_cache.py b/pym/portage/eclass_cache.py
index 26019400b..39e29d540 100644
--- a/pym/portage/eclass_cache.py
+++ b/pym/portage/eclass_cache.py
@@ -5,6 +5,7 @@
__all__ = ["cache"]
+import stat
import sys
import warnings
from portage.util import normalize_path
@@ -95,7 +96,7 @@ class cache(object):
if not y.endswith(".eclass"):
continue
try:
- mtime = long(os.stat(os.path.join(x, y)).st_mtime)
+ mtime = os.stat(os.path.join(x, y))[stat.ST_MTIME]
except OSError:
continue
ys=y[:-eclass_len]