lean_towards_being_utf8 |= NAME_INDICATES_UTF8;
}
+ const char * orig_CTYPE_locale = toggle_locale_c(LC_CTYPE, locale);
+
/* For this portion of the file to compile, some C99 functions aren't
* available to us, even though we now require C99. So, something must be
* wrong with them. The code here should be good enough to work around
return ""; /* The name is wrong; override */
}
+ restore_toggled_locale_c(LC_CTYPE, orig_CTYPE_locale);
return codeset;
}
/* But if the locale could be UTF-8, and also the name corroborates this,
* assume it is so */
if (lean_towards_being_utf8 & NAME_INDICATES_UTF8) {
+ restore_toggled_locale_c(LC_CTYPE, orig_CTYPE_locale);
return codeset;
}
# endif
+ restore_toggled_locale_c(LC_CTYPE, orig_CTYPE_locale);
+
Safefree(scratch_buf);
scratch_buf = NULL;