aboutsummaryrefslogtreecommitdiff
path: root/src/mm-base-sim.c
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2020-11-26 23:07:11 +0100
committerAleksander Morgado <aleksander@aleksander.es>2021-02-23 11:35:11 +0000
commit5ce97abd73da12b64393be798f2c294d29be2705 (patch)
tree48010cd5880f1dc07fd24e2156ecd7fd9290622b /src/mm-base-sim.c
parent5480cb67b283c078770b02766c37768cb0930d7b (diff)
charsets: make translit optional in gsm_unpacked_to_utf8()
Until now, this method would automatically apply transliteration; i.e. replacing characters with '?' when no direct translation was available. We can attempt to do that transliteration on strings that are not critical, e.g. the operator name reported by the network. But we should not do that on other types of strings, e.g. on SMS contents that may really have additional purposes than just being human-readable. This commit makes the transliteration option to be explicitly requested by the caller.
Diffstat (limited to 'src/mm-base-sim.c')
-rw-r--r--src/mm-base-sim.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mm-base-sim.c b/src/mm-base-sim.c
index 0e00342c..f50af820 100644
--- a/src/mm-base-sim.c
+++ b/src/mm-base-sim.c
@@ -1427,7 +1427,7 @@ parse_spn (const gchar *response,
buflen--;
/* First byte is metadata; remainder is GSM-7 unpacked into octets; convert to UTF8 */
- return (gchar *)mm_charset_gsm_unpacked_to_utf8 (bin + 1, buflen - 1);
+ return (gchar *)mm_charset_gsm_unpacked_to_utf8 (bin + 1, buflen - 1, FALSE, error);
}
g_set_error (error, MM_CORE_ERROR, MM_CORE_ERROR_FAILED,