Re: set modification date of symlink
Re: set modification date of symlink
- Subject: Re: set modification date of symlink
- From: "Gerriet M. Denkmann" <email@hidden>
- Date: Fri, 20 Jul 2007 20:29:23 +0200
On 20 Jul 2007, at 15:29, Alastair Houghton wrote:
On 20 Jul 2007, at 11:13, Gerriet M. Denkmann wrote:
I am trying to set the modification date of a symbolic link.
It seems that [NSFileManager changeFileAttributes:atPath:]
traverses through symbolic links (although this is NOT mentioned
in the documentation).
man symlink(7) says: "The [...] modification time of an existing
symbolic link can be changed by means of the lutimes(2) system
call [...]."
But there is no man lutimes(2) and lutimes() is NOT defined in
<sys/time.h>.
Using lutimes() creates an undefined symbol error while linking.
So: How to set the modification date of symlink?
setattrlist() should work, on volumes that support it.
Yes, it should work. But it seems not to work.
I wrote a small tool to set the creation time using setattrlist() -
it works as expected for regular files and directories, it does
nothing (not even some error message) for symbolic links.
Kind regards,
Gerriet.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden