I have a source file with NSFileModificationDate 2011-09-21 20:12:29 +0000
I copy this date to the destination file and I get 2011-09-21 20:12:28 +0000
So, one second earlier. This happens only on a FAT16 USB-key volume. If I do
that on a file on a MacOSX volume I get the same date. Correct. I do:

    scrDict = [mManager attributesOfItemAtPath:srcPath error:nil];
    srcDate = [srcDict objectForKey:NSFileModificationDate];
    dstDict = [NSMutableDictionary dictionaryWithDictionary:
                      [mManager attributesOfItemAtPath:dstPath error:nil]];
    [dstDict setObject:srcDate  forKey:NSFileModificationDate]
    [mManager setAttributes:dstDict ofItemAtPath:dstPath error:nil];

I also tried to just copy the file with copyItemAtPath:...
Same results. Ok on Mac volume, wrong on the USB key.

And I even tried to set the date by the method FSSetCatalogInfo with
kFSCatInfoContentMod. Same results. This has been reported from my clients
too on their own USB keys.

Why doesn't it properly work on a FAT16 USB key? (FAT16 is what Disk Utility
reports, even after a new Erase as MS-DOS (FAT).
Do I miss something?
Is it a bug?
How to workaround this trouble?


Regards
-- Leonardo


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to