Handle locales more safely.