aboutsummaryrefslogtreecommitdiffstats
path: root/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java
diff options
context:
space:
mode:
Diffstat (limited to 'java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java')
-rw-r--r--java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java
index 0f7d2f6c9..d5516ef46 100644
--- a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java
+++ b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java
@@ -460,8 +460,10 @@ public final class BinaryDictIOUtils {
destination.write((byte)infos.length);
break;
case 2:
- destination.write((byte)(infos.length >> 8));
- destination.write((byte)(infos.length & 0xFF));
+ final int encodedPtNodeCount =
+ infos.length | FormatSpec.LARGE_PTNODE_ARRAY_SIZE_FIELD_SIZE_FLAG;
+ destination.write((byte)(encodedPtNodeCount >> 8));
+ destination.write((byte)(encodedPtNodeCount & 0xFF));
break;
default:
throw new RuntimeException("Invalid node count size.");