summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2010-10-14 14:46:11 +0800
committerPeng Wu <alexepico@gmail.com>2010-10-14 14:46:11 +0800
commitd51091e95735909b48f025be18238cd2f7b3931f (patch)
tree4e55e2121d4e9a0348eb19cc41c6fce21e230754
parenta99fa36f8e6a75f2c305a07e08354fa881a1a124 (diff)
downloadlibpinyin-d51091e95735909b48f025be18238cd2f7b3931f.tar.gz
libpinyin-d51091e95735909b48f025be18238cd2f7b3931f.tar.xz
libpinyin-d51091e95735909b48f025be18238cd2f7b3931f.zip
fixes compile warning for pinyin_lookup.h
-rwxr-xr-xsrc/include/novel_types.h1
-rw-r--r--src/lookup/pinyin_lookup.h2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/include/novel_types.h b/src/include/novel_types.h
index 6f33a9e..82a9947 100755
--- a/src/include/novel_types.h
+++ b/src/include/novel_types.h
@@ -125,6 +125,7 @@ enum AttachOption{
#define MAX_PHRASE_LENGTH 16
+const phrase_token_t null_token = 0;
const phrase_token_t sentence_start = 1;
const phrase_token_t token_min = 0;
const phrase_token_t token_max = UINT_MAX;
diff --git a/src/lookup/pinyin_lookup.h b/src/lookup/pinyin_lookup.h
index e585788..0e8287f 100644
--- a/src/lookup/pinyin_lookup.h
+++ b/src/lookup/pinyin_lookup.h
@@ -45,7 +45,7 @@ struct lookup_value_t{
gint32 m_last_step;
lookup_value_t(gfloat poss = FLT_MAX){
- m_handles[0] = NULL; m_handles[1] = NULL;
+ m_handles[0] = null_token; m_handles[1] = null_token;
m_poss = poss;
m_last_step = -1;
}