fixed some locale related issues