From db47cf762436803aadaa8ed909a6fd1b3390f629 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Thu, 26 Nov 2009 21:59:51 +0000 Subject: [PATCH] In movefile(), skip os.utime() when os.rename() succeeds, in order to completely preserve mtime resolution. svn path=/main/trunk/; revision=14897 --- pym/portage/__init__.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index 2641472e5..3246a3a51 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -7565,6 +7565,8 @@ def movefile(src, dest, newmtime=None, sstat=None, mysettings=None, try: if hardlinked: newmtime = long(os.stat(dest).st_mtime) + elif not renamefailed: + newmtime = long(sstat.st_mtime) else: if newmtime is not None: os.utime(dest, (newmtime, newmtime)) -- 2.26.2