Fix a case conversion bug
authorMatthias Clasen <mclasen@redhat.com>
Mon, 21 Nov 2011 05:27:25 +0000 (00:27 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 21 Nov 2011 05:28:41 +0000 (00:28 -0500)
For titlecase chars without uppercase variant, we were returning
0, contrary to the docs.

glib/guniprop.c

index 2879a80..c099256 100644 (file)
@@ -603,7 +603,7 @@ g_unichar_toupper (gunichar c)
       for (i = 0; i < G_N_ELEMENTS (title_table); ++i)
        {
          if (title_table[i][0] == c)
-           return title_table[i][1];
+           return title_table[i][1] ? title_table[i][1] : c;
        }
     }
   return c;