I've tried the patch cited by Frederik Himpe, on a Debian Testing system. I've made some modification to the patch to make it working when some locale variables are missing or wrong.
Aclually it checks both LANG and LC_CTYPE, and more importantly does not fail if one of the is not set.
In this case C locale (with US-ASCII encoding) is used, mainly to make it working when the system has not utf-8 locales installed or the configuration is erroneous.
I've tried the patch cited by Frederik Himpe, on a Debian Testing system. I've made some modification to the patch to make it working when some locale variables are missing or wrong.
Aclually it checks both LANG and LC_CTYPE, and more importantly does not fail if one of the is not set.
In this case C locale (with US-ASCII encoding) is used, mainly to make it working when the system has not utf-8 locales installed or the configuration is erroneous.