summaryrefslogtreecommitdiff
path: root/user/modemmanager/no-translit.patch
blob: 8f6d4b5f730881f48d3c56471c223e319d8fdd61 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
--- ModemManager-1.10.0/src/mm-broadband-modem.c.old	2019-01-15 14:57:35.000000000 +0000
+++ ModemManager-1.10.0/src/mm-broadband-modem.c	2019-05-10 05:17:07.329881242 +0000
@@ -7014,7 +7014,7 @@
         /* The raw SMS data can only be GSM, UCS2, or unknown (8-bit), so we
          * need to convert to UCS2 here.
          */
-        ucs2_text = g_convert (text, -1, "UCS-2BE//TRANSLIT", "UTF-8", NULL, &ucs2_len, NULL);
+        ucs2_text = g_convert (text, -1, "UCS-2BE", "UTF-8", NULL, &ucs2_len, NULL);
         g_assert (ucs2_text);
         raw = g_byte_array_sized_new (ucs2_len);
         g_byte_array_append (raw, (const guint8 *) ucs2_text, ucs2_len);
--- ModemManager-1.10.0/src/mm-charsets.c.old	2019-05-10 05:09:21.350652258 +0000
+++ ModemManager-1.10.0/src/mm-charsets.c	2019-05-10 05:16:41.752668021 +0000
@@ -35,15 +35,15 @@
 } CharsetEntry;
 
 static CharsetEntry charset_map[] = {
-    { "UTF-8",   "UTF8",   "UTF-8",     "UTF-8//TRANSLIT",     MM_MODEM_CHARSET_UTF8 },
-    { "UCS2",    NULL,     "UCS-2BE",   "UCS-2BE//TRANSLIT",   MM_MODEM_CHARSET_UCS2 },
-    { "IRA",     "ASCII",  "ASCII",     "ASCII//TRANSLIT",     MM_MODEM_CHARSET_IRA },
-    { "GSM",     NULL,     NULL,        NULL,                  MM_MODEM_CHARSET_GSM },
-    { "8859-1",  NULL,     "ISO8859-1", "ISO8859-1//TRANSLIT", MM_MODEM_CHARSET_8859_1 },
-    { "PCCP437", "CP437",  "CP437",     "CP437//TRANSLIT",     MM_MODEM_CHARSET_PCCP437 },
-    { "PCDN",    "CP850",  "CP850",     "CP850//TRANSLIT",     MM_MODEM_CHARSET_PCDN },
-    { "HEX",     NULL,     NULL,        NULL,                  MM_MODEM_CHARSET_HEX },
-    { NULL,      NULL,     NULL,        NULL,                  MM_MODEM_CHARSET_UNKNOWN }
+    { "UTF-8",   "UTF8",   "UTF-8",     "UTF-8",     MM_MODEM_CHARSET_UTF8 },
+    { "UCS2",    NULL,     "UCS-2BE",   "UCS-2BE",   MM_MODEM_CHARSET_UCS2 },
+    { "IRA",     "ASCII",  "ASCII",     "ASCII",     MM_MODEM_CHARSET_IRA },
+    { "GSM",     NULL,     NULL,        NULL,        MM_MODEM_CHARSET_GSM },
+    { "8859-1",  NULL,     "ISO8859-1", "ISO8859-1", MM_MODEM_CHARSET_8859_1 },
+    { "PCCP437", "CP437",  "CP437",     "CP437",     MM_MODEM_CHARSET_PCCP437 },
+    { "PCDN",    "CP850",  "CP850",     "CP850",     MM_MODEM_CHARSET_PCDN },
+    { "HEX",     NULL,     NULL,        NULL,        MM_MODEM_CHARSET_HEX },
+    { NULL,      NULL,     NULL,        NULL,        MM_MODEM_CHARSET_UNKNOWN }
 };
 
 const char *
@@ -163,7 +163,7 @@
     g_return_val_if_fail (iconv_from != NULL, FALSE);
 
     converted = g_convert ((const gchar *)array->data, array->len,
-                           "UTF-8//TRANSLIT", iconv_from,
+                           "UTF-8", iconv_from,
                            NULL, NULL, &error);
     if (!converted || error) {
         g_clear_error (&error);
@@ -195,7 +195,7 @@
         return unconverted;
 
     converted = g_convert (unconverted, unconverted_len,
-                           "UTF-8//TRANSLIT", iconv_from,
+                           "UTF-8", iconv_from,
                            NULL, NULL, &error);
     if (!converted || error) {
         g_clear_error (&error);
@@ -226,7 +226,7 @@
         return g_strdup (src);
 
     converted = g_convert (src, strlen (src),
-                           iconv_to, "UTF-8//TRANSLIT",
+                           iconv_to, "UTF-8",
                            NULL, &converted_len, &error);
     if (!converted || error) {
         g_clear_error (&error);
@@ -747,7 +747,7 @@
 
         iconv_from = charset_iconv_from (charset);
         utf8 = g_convert (str, strlen (str),
-                          "UTF-8//TRANSLIT", iconv_from,
+                          "UTF-8", iconv_from,
                           NULL, NULL, &error);
         if (!utf8 || error) {
             g_clear_error (&error);
@@ -790,7 +790,7 @@
          * that is UTF-8, if any.
          */
         utf8 = g_convert (str, strlen (str),
-                          "UTF-8//TRANSLIT", "UTF-8//TRANSLIT",
+                          "UTF-8", "UTF-8",
                           &bread, &bwritten, NULL);
 
         /* Valid conversion, or we didn't get enough valid UTF-8 */
@@ -804,7 +804,7 @@
          */
         str[bread] = '\0';
         utf8 = g_convert (str, strlen (str),
-                          "UTF-8//TRANSLIT", "UTF-8//TRANSLIT",
+                          "UTF-8", "UTF-8",
                           NULL, NULL, NULL);
         g_free (str);
         break;