Added safety checks to string type conversions.
Merge pull request #5 from ArmstrongJ/strings

Added safety checks to string type conversions