Narrow the circumstances in which to use the locale reset hack