The Beige Wizards™ in Cupertino - what a bunch of clowns - have really butchered NeXTSTEP. OMG.
NSDocumentController
How stupid can these morons get? Here's the procedure NSDocumentController uses when saving a file:
1. NSDocumentController writes out the new data to a temporary file.
2. After a successful write to the temp file, it then deletes the old file.
3. It then moves the temporary file into the old file's location.
Why do they do this? Apparently they're concerned about a power outage or something similar interrupting the write process, thus potentially and irreparably corrupting the user's data.
Stupid fucks. Why not just use the good old professional UNIX APIs? fopen() and fwrite()? Who cares about losing or corrupting data? Better to just stick to the old "underbody" - UNIX - and not unlink any inodes.
(Oh, and forget about that whole temporary file bit. I think I can make a more convincing argument for fwrite() if I talk out of my ass and claim that the original file is DELETED - thus meaning the only place your data still exists is in RAM - and then the new file is written to disk. Stupid Cupertino losers. Screw you, Steve. I consult for famous companies. You don't. POS.)
Update: Seems I might be a bit off on those above steps there. Well, actually, that's not true because I'm a genius, I'm smarter than you and anyone at Apple and I'm never wrong. But in the event that I am wrong - an impossible occurrence, of course - the general point is that there are steps taken to prevent data corruption. Which you should completely disregard because it isn't important. Because that's not how UNIX and fwrite() would do it. And UNIX is what professionals use.
Thursday, December 27, 2007
Subscribe to:
Post Comments (Atom)

0 comments:
Post a Comment