fi_tostr fixes

Two fixes for fi_str:

1. Don't use ```__thread``` for TSD; it's a GCC extension.  So just explicitly declare that fi_tostr() is not thread safe.
1. Ensure that fi_tostr() does not overflow its buffer.
Works for me.