Talk About Network

Google





Mac > Mac Programmer Help > FSSetCatalogInf...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 3711 of 3889
Post > Topic >>

FSSetCatalogInfo gotcha

by Gregory Weston <uce@[EMAIL PROTECTED] > Apr 18, 2008 at 05:17 PM

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.
 




 1 Posts in Topic:
FSSetCatalogInfo gotcha
Gregory Weston <uce@[E  2008-04-18 17:17:03 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
localhost-V2008-12-19 Wed Jan 7 19:15:54 PST 2009.