Add locale support when getting the case of a string
Refactor how sms is process to fix a potential memory leak