its translated messages. textdomain(textdomain(NULL)) clears the cache.
$Id$
+Thu Dec 8 11:48:34 EST 2005 ajc
+* Fix "locale leak" on newer Linux systems where gettext() seems to cache
+ its translated messages. textdomain(textdomain(NULL)) clears the cache.
+
Wed Dec 7 22:22:09 EST 2005 ajc
* Improved the reliability of per-thread locale by unsetting it at the end
of each transaction.
* Activate and deactivate the selected language for this session.
*/
void go_selected_language(void) {
- uselocale(wc_locales[WC->selected_language]);
+ uselocale(wc_locales[WC->selected_language]); /* switch locales */
+ textdomain(textdomain(NULL)); /* clear the cache */
}
void stop_selected_language(void) {
- uselocale(LC_GLOBAL_LOCALE);
+ uselocale(LC_GLOBAL_LOCALE); /* switch locales */
+ textdomain(textdomain(NULL)); /* clear the cache */
}