Re: strlen()
Agreed.
For strings from an external source I use my own simple unsigned counting scheme, and if it looks like it's about to hit the buffers the remainder all goes to /dev/null. The fact is flagged so the program can decide what to do next.