From: Zac Medico Date: Wed, 6 Jun 2007 03:37:11 +0000 (-0000) Subject: Comment in portage.movefile() that it's impossible to preserve timestamps of a symlin... X-Git-Tag: v2.2_pre1~1290 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=65764654946644f5c0b36ca106e79e097fcba44d;p=portage.git Comment in portage.movefile() that it's impossible to preserve timestamps of a symlink since utime() only works on the target. svn path=/main/trunk/; revision=6740 --- diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py index db268e5fd..901e25875 100644 --- a/pym/portage/__init__.py +++ b/pym/portage/__init__.py @@ -3971,6 +3971,8 @@ def movefile(src,dest,newmtime=None,sstat=None,mysettings=None): else: os.symlink(target,dest) lchown(dest,sstat[stat.ST_UID],sstat[stat.ST_GID]) + # utime() only works on the target of a symlink, so it's not + # possible to perserve mtime on symlinks. return os.lstat(dest)[stat.ST_MTIME] except SystemExit, e: raise