https://github.com/unicode-org/icu/commit/7bc1b89eb83abc0495e30da5efda8871ff0ab81c --- icu/source/tools/gendict/gendict.cpp.orig +++ icu/source/tools/gendict/gendict.cpp @@ -438,7 +438,9 @@ fprintf(f, "transform_type = \"%s\"\n", isOffset ? "offset" : "none"); fprintf(f, "transform_offset = %d\n", offset); - usrc_writeArray(f, "trie_data = [\n ", outData, isBytesTrie ? 8 : 16, outDataSize, " ", "\n]\n"); + int32_t outDataWidth = isBytesTrie ? 8 : 16; + int32_t outDataLength = isBytesTrie ? outDataSize : outDataSize / U_SIZEOF_UCHAR; + usrc_writeArray(f, "trie_data = [\n ", outData, outDataWidth, outDataLength, " ", "\n]\n"); fclose(f);