summaryrefslogtreecommitdiffstats
path: root/src/storage
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2016-07-01 12:04:23 +0800
committerPeng Wu <alexepico@gmail.com>2016-07-01 12:04:23 +0800
commita6822d0946427c803d5f3952c934224bbb537907 (patch)
treef2e4278fcc5f6fc529ea8cd025573cf0b67b726f /src/storage
parentb014b923a06a469b4f3e96640e2b4d375e5b6268 (diff)
downloadlibpinyin-a6822d0946427c803d5f3952c934224bbb537907.tar.gz
libpinyin-a6822d0946427c803d5f3952c934224bbb537907.tar.xz
libpinyin-a6822d0946427c803d5f3952c934224bbb537907.zip
fixes compile
Diffstat (limited to 'src/storage')
-rw-r--r--src/storage/chewing_large_table2_bdb.cpp1
-rw-r--r--src/storage/phrase_large_table3_bdb.cpp1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/storage/chewing_large_table2_bdb.cpp b/src/storage/chewing_large_table2_bdb.cpp
index 4813bff..66ea188 100644
--- a/src/storage/chewing_large_table2_bdb.cpp
+++ b/src/storage/chewing_large_table2_bdb.cpp
@@ -402,6 +402,7 @@ bool ChewingLargeTable2::mask_out(phrase_token_t mask,
memset(&db_data, 0, sizeof(DBT));
/* Iterate over the database, retrieving each record in turn. */
+ int ret = 0;
while((ret = cursorp->c_get(cursorp, &db_key, &db_data, DB_NEXT)) == 0) {
int phrase_length = db_key.size / sizeof(ChewingKey);
diff --git a/src/storage/phrase_large_table3_bdb.cpp b/src/storage/phrase_large_table3_bdb.cpp
index cbcd40f..dcb34b8 100644
--- a/src/storage/phrase_large_table3_bdb.cpp
+++ b/src/storage/phrase_large_table3_bdb.cpp
@@ -292,6 +292,7 @@ bool PhraseLargeTable3::mask_out(phrase_token_t mask,
memset(&db_data, 0, sizeof(DBT));
/* Iterate over the database, retrieving each record in turn. */
+ int ret = 0;
while((ret = cursorp->c_get(cursorp, &db_key, &db_data, DB_NEXT)) == 0) {
entry.m_chunk.set_chunk(db_data.data, db_data.size, NULL);