composetable: Fix algorithmic matching

The code wasn't paying attention to (lack of) nul-termination
in one place, causing it to not match when it should.
This commit is contained in:
Matthias Clasen 2021-02-01 21:51:51 -05:00
parent 8d18d93742
commit ef053ebb4a

View File

@ -1115,7 +1115,7 @@ check_normalize_nfc (gunichar *combination_buffer,
for (i = 0; i < n_combinations; i++)
{
g_unicode_canonical_ordering (combination_buffer_temp, n_compose);
combination_utf8_temp = g_ucs4_to_utf8 (combination_buffer_temp, -1, NULL, NULL, NULL);
combination_utf8_temp = g_ucs4_to_utf8 (combination_buffer_temp, n_compose, NULL, NULL, NULL);
nfc_temp = g_utf8_normalize (combination_utf8_temp, -1, G_NORMALIZE_NFC);
if (g_utf8_strlen (nfc_temp, -1) == 1)