summaryrefslogtreecommitdiffstats
path: root/src/storage
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2016-05-30 11:09:49 +0800
committerPeng Wu <alexepico@gmail.com>2016-05-30 11:09:49 +0800
commitb735c7d1074fb8234f555c34739d3979a5e2e3fe (patch)
tree792e338b082259bd5f3d8db959f9a3812c983fc8 /src/storage
parent08b469c70f3ec625ce5186bfcb97763c323e1cc5 (diff)
downloadlibpinyin-b735c7d1074fb8234f555c34739d3979a5e2e3fe.tar.gz
libpinyin-b735c7d1074fb8234f555c34739d3979a5e2e3fe.tar.xz
libpinyin-b735c7d1074fb8234f555c34739d3979a5e2e3fe.zip
fixes a typo
Diffstat (limited to 'src/storage')
-rw-r--r--src/storage/phonetic_key_matrix.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/storage/phonetic_key_matrix.cpp b/src/storage/phonetic_key_matrix.cpp
index 5ca7e9b..360a00a 100644
--- a/src/storage/phonetic_key_matrix.cpp
+++ b/src/storage/phonetic_key_matrix.cpp
@@ -344,6 +344,7 @@ gfloat compute_pronunciation_possibility(PhoneticKeyMatrix * matrix,
assert(matrix->get_column_size(start) > 0);
assert(matrix->get_column_size(end) > 0);
+ g_array_set_size(cached_keys, 0);
return compute_pronunciation_possibility_recur
(matrix, start, end, cached_keys, item);
}
@@ -411,6 +412,7 @@ bool increase_pronunciation_possibility(PhoneticKeyMatrix * matrix,
assert(matrix->get_column_size(start) > 0);
assert(matrix->get_column_size(end) > 0);
+ g_array_set_size(cached_keys, 0);
return increase_pronunciation_possibility_recur
(matrix, start, end, cached_keys, item, delta);
}