diff options
author | 2014-02-24 13:57:46 +0000 | |
---|---|---|
committer | 2014-02-24 13:57:46 +0000 | |
commit | 6e224a236a0a7cd253f74c7ed8b9a8f2eea41600 (patch) | |
tree | 9214094f6008e98fcca15af9453ca4f232ad55b8 /java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java | |
parent | 64ace089a8cde06ff030aa491b798ec7d32a3ad7 (diff) | |
parent | 890b44e5376413adc73025e046072bcce3e119c5 (diff) | |
download | latinime-6e224a236a0a7cd253f74c7ed8b9a8f2eea41600.tar.gz latinime-6e224a236a0a7cd253f74c7ed8b9a8f2eea41600.tar.xz latinime-6e224a236a0a7cd253f74c7ed8b9a8f2eea41600.zip |
Merge "Correctly read the header of APK-embedded dicts"
Diffstat (limited to 'java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java')
-rw-r--r-- | java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java index 989ca4b2f..90e7400fb 100644 --- a/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java +++ b/java/src/com/android/inputmethod/latin/makedict/BinaryDictIOUtils.java @@ -237,7 +237,7 @@ public final class BinaryDictIOUtils { final File file, final long offset, final long length) throws FileNotFoundException, IOException, UnsupportedFormatException { final byte[] buffer = new byte[HEADER_READING_BUFFER_SIZE]; - final DictDecoder dictDecoder = FormatSpec.getDictDecoder(file, + final DictDecoder dictDecoder = FormatSpec.getDictDecoder(file, offset, length, new DictDecoder.DictionaryBufferFactory() { @Override public DictBuffer getDictionaryBuffer(File file) @@ -251,8 +251,7 @@ public final class BinaryDictIOUtils { inStream.close(); } } - } - ); + }); if (dictDecoder == null) { return null; } |