summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2012-01-04 17:46:01 +0800
committerPeng Wu <alexepico@gmail.com>2012-01-04 17:46:01 +0800
commit8af616069b4805d43dc554a33d7d4503f9a87782 (patch)
tree67d710209a0ee90aa69e0610e74f80b3e8d1b8b5
parent97c269ad379d7001d067757e556cbd0a7c30240c (diff)
downloadlibpinyin-8af616069b4805d43dc554a33d7d4503f9a87782.zip
libpinyin-8af616069b4805d43dc554a33d7d4503f9a87782.tar.gz
libpinyin-8af616069b4805d43dc554a33d7d4503f9a87782.tar.xz
fixes crash
-rw-r--r--src/storage/pinyin_parser2.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/storage/pinyin_parser2.cpp b/src/storage/pinyin_parser2.cpp
index 932a8eb..483f4ed 100644
--- a/src/storage/pinyin_parser2.cpp
+++ b/src/storage/pinyin_parser2.cpp
@@ -728,7 +728,7 @@ bool ChewingParser2::parse_one_key(pinyin_option_t options,
}
/* search the chewing in the chewing index table. */
- if (search_chewing_index(options, chewing, key)) {
+ if (chewing && search_chewing_index(options, chewing, key)) {
/* save back tone if available. */
key.m_tone = tone;
g_free(chewing);