Sort out error handling everywhere a charset name is converted into