diff options
author | Peng Wu <alexepico@gmail.com> | 2011-04-01 11:03:46 +0800 |
---|---|---|
committer | Peng Wu <alexepico@gmail.com> | 2011-04-02 15:11:18 +0800 |
commit | f1f777630f85e58b01b472da23e3f72a71dd1f49 (patch) | |
tree | 5f41f2bd66ef04b41950a9a67ee39459dd46b587 /src/storage/ngram.cpp | |
parent | 37498f130e673dcb3052c029c0407ffa483dda8a (diff) | |
download | libpinyin-f1f777630f85e58b01b472da23e3f72a71dd1f49.tar.gz libpinyin-f1f777630f85e58b01b472da23e3f72a71dd1f49.tar.xz libpinyin-f1f777630f85e58b01b472da23e3f72a71dd1f49.zip |
refine code
Diffstat (limited to 'src/storage/ngram.cpp')
-rw-r--r-- | src/storage/ngram.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/storage/ngram.cpp b/src/storage/ngram.cpp index 8ea8334..c6b1736 100644 --- a/src/storage/ngram.cpp +++ b/src/storage/ngram.cpp @@ -38,15 +38,15 @@ SingleGram::SingleGram(void * buffer, size_t length){ m_chunk.set_chunk(buffer, length, NULL); } -bool SingleGram::set_total_freq(guint32 m_total){ +bool SingleGram::set_total_freq(guint32 total){ char * buf_begin = (char *)m_chunk.begin(); - *((guint32 *)buf_begin) = m_total; + *((guint32 *)buf_begin) = total; return true; } -bool SingleGram::get_total_freq(guint32 & m_total){ +bool SingleGram::get_total_freq(guint32 & total){ char * buf_begin = (char *)m_chunk.begin(); - m_total = *((guint32 *)buf_begin); + total = *((guint32 *)buf_begin); return true; } |