[[ Bug 13219 ]] Fix potential crash in OSX locale caching