Bug 477756

Summary: Incorrect LANG environment variable handling
Product: [Fedora] Fedora Reporter: Tomáš Windsor <windsor>
Component: gtkspellAssignee: Matthew Barnes <mbarnes>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 10CC: mbarnes
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-01-07 09:06:47 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Tomáš Windsor 2008-12-23 11:20:42 UTC
Description of problem:
Locales starting with char 'C' are not correctly detected from the LANG environment variable.

Version-Release number of selected component (if applicable):
2.0.13-1.fc10

How reproducible:
E.g. on Tomboy application.

Steps to Reproduce:
1. export LANG=cs_CZ.UTF-8
2. tomboy
  
Actual results:
Czech spellchecker not working in Tomboy.

Expected results:
Czech spellchecker working in Tomboy.

Additional info:
Seems to be caused by following part of code in gtkspell.c

static gboolean
gtkspell_set_language_internal(GtkSpell *spell, const gchar *lang, GError **error) {

	if (lang == NULL) {
		lang = g_getenv("LANG");
		if (lang) {
			if (g_strncasecmp(lang, "C", 1) == 0)
				lang = NULL;
			else if (lang[0] == 0)
				lang = NULL;

Comment 1 Fedora Update System 2008-12-23 13:13:52 UTC
gtkspell-2.0.15-1.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/gtkspell-2.0.15-1.fc10

Comment 2 Fedora Update System 2008-12-24 18:45:50 UTC
gtkspell-2.0.15-1.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update gtkspell'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2008-11794

Comment 3 Fedora Update System 2009-01-07 09:06:44 UTC
gtkspell-2.0.15-1.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.