]> git.pld-linux.org Git - packages/gnome-control-center.git/commitdiff
- fix segfault on esperanto (https://bugzilla.gnome.org/show_bug.cgi?id=661866) auto/th/gnome-control-center-3_2_0-2
authorArtur Frysiak <artur@frysiak.net>
Sat, 15 Oct 2011 20:20:08 +0000 (20:20 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- rel. 2

Changed files:
    gnome-control-center.spec -> 1.57
    territory_code.patch -> 1.1

gnome-control-center.spec
territory_code.patch [new file with mode: 0644]

index 1a4f4b79c654c16cc0d991a3e5bd891cb9a83b35..7a385dfce865b63ac32890e2c0aa1bc88f4f88e6 100644 (file)
@@ -6,7 +6,7 @@ Summary(ru.UTF-8):      Центр управления GNOME
 Summary(uk.UTF-8):     Центр керування GNOME
 Name:          gnome-control-center
 Version:       3.2.0
-Release:       1
+Release:       2
 Epoch:         1
 License:       GPL v2+
 Group:         X11/Applications
@@ -15,6 +15,7 @@ Source0:      http://ftp.gnome.org/pub/GNOME/sources/gnome-control-center/3.2/%{name}
 # PLD-specific patches
 Patch0:                system-locale-archive-path.patch
 Patch1:                configure-gettext.patch
+Patch2:                territory_code.patch
 URL:           http://www.gnome.org/
 BuildRequires: GConf2-devel >= 2.26.0
 # use libnm-gtk - will use correct NM version
@@ -149,6 +150,7 @@ Pliki nagłówkowe bibliotek GNOME Control Center.
 %setup -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
 
 %build
 %{__gnome_doc_prepare}
diff --git a/territory_code.patch b/territory_code.patch
new file mode 100644 (file)
index 0000000..7c9edd1
--- /dev/null
@@ -0,0 +1,28 @@
+commit cbda9c4c6bbbeff84895f9fefb61cdc90129c68b
+Author: Artur Frysiak <wiget@pld-linux.org>
+Date:   Sat Oct 15 22:09:26 2011 +0200
+
+    Fix segfault on locale without territory.
+    
+    Some locale (eg. Esperanto) don't have territory. Check
+    locale->territory_code before using it.
+
+diff --git a/panels/common/gdm-languages.c b/panels/common/gdm-languages.c
+index 2dfc436..392e693 100644
+--- a/panels/common/gdm-languages.c
++++ b/panels/common/gdm-languages.c
+@@ -635,9 +635,11 @@ count_languages_and_territories (void)
+               count++;
+               g_hash_table_insert (gdm_language_count_map, g_strdup (locale->language_code), GINT_TO_POINTER (count));
+-              count = GPOINTER_TO_INT (g_hash_table_lookup (gdm_territory_count_map, locale->territory_code));
+-              count++;
+-              g_hash_table_insert (gdm_territory_count_map, g_strdup (locale->territory_code), GINT_TO_POINTER (count));
++              if (locale->territory_code) {
++                      count = GPOINTER_TO_INT (g_hash_table_lookup (gdm_territory_count_map, locale->territory_code));
++                      count++;
++                      g_hash_table_insert (gdm_territory_count_map, g_strdup (locale->territory_code), GINT_TO_POINTER (count));
++              }
+         }
+ }
This page took 0.03664 seconds and 4 git commands to generate.