summaryrefslogtreecommitdiffstats
path: root/src/pinyin.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/pinyin.cpp')
-rw-r--r--src/pinyin.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pinyin.cpp b/src/pinyin.cpp
index 6d8738c..29c4c8c 100644
--- a/src/pinyin.cpp
+++ b/src/pinyin.cpp
@@ -2488,9 +2488,6 @@ static bool _get_char_offset_recur(pinyin_instance_t * instance,
const size_t newstart = key_rest.m_raw_end;
- if (newstart > offset)
- return true;
-
const ChewingKey zero_key;
if (zero_key == key) {
/* assume only one key here for "'" or the last key. */
@@ -2508,6 +2505,9 @@ static bool _get_char_offset_recur(pinyin_instance_t * instance,
if (pinyin_poss < FLT_EPSILON)
continue;
+ if (newstart > offset)
+ return true;
+
++length;
result = _get_char_offset_recur