Seems there's been a spate of gotchas posted recently, so I thought I'd
mention two that I've found.
Gotcha #1: The FAT filesystem on Mac OS X doesn't reliably cope with the
read-only flag being set on a directory. That flag doesn't apply to
directories on FAT volumes, and sometimes the FS knows that. But most of
the time it doesn't and if you somehow end up with a directory with that
bit set in the attributes flag it will be treated as meaning that the
directory cannot be modified. As far as I can tell, the only part of the
FS code that knows that flag doesn't apply to directories is the part
that would let you *change* the flag. So if you do run across a
directory with that bit set - apparently quite rare, but it happened for
one of my users - there's absolutely no way to fix it on a Mac.
Gotcha #2: If you try to, using FSSetCatalogInfo, it will fail *but* you
will get noErr as a result code. When I re****ted this I was told that
it's policy to not return an error from an attempt to change the lock
state of a file. So if you try to use FSSetCatalogInfo to set or clear
the lock flag on a file, the only way to reliably determine that it
worked is a follow-up call to FSGetCatalogInfo.