Blog spam count: 2007-09
Monday, October 1st, 2007Spam comments blocked by Negative Turing Test in September 2007 (excluding September 1–3):
6,826
Spam comments blocked by Negative Turing Test in September 2007 (excluding September 1–3):
6,826
If you work on an [added: a document-based] app that uses a plist-based format, you should test your plist-reading code to see how it handles an invalid (e.g., eaten by the user’s dog) plist. Here’s one:
<plist>
<qux></qux>
</plist>
The binary plist parser won’t even touch it because it doesn’t have the bplist header, the XML parser will choke on it because it contains an element that it doesn’t recognize, and the OpenStep parser will choke on it because the first line doesn’t end with a semicolon or backslash.
When you feed this to your app, your app should present an error message. Anything else is a bug. (UPDATE 2007-10-02: OK, maybe not. There’s at least one circumstance where you can ignore it, as pointed out in the comments. I still think I’m right in most circumstances, just clearly not all.)