Simple code crashes with no apparent cause

I'll try out the PString and Streaming libraries, it seems like they might provide a much better starting point than String anyway.

PString is not significantly different from WString. It still allocates and deallocates memory (which is where the bug is). It is not a magical way to avoid using char arrays and doing the work yourself.