summaryrefslogtreecommitdiffstats
path: root/utils
diff options
context:
space:
mode:
authorPeng Wu <alexepico@gmail.com>2011-07-18 14:48:46 +0800
committerPeng Wu <alexepico@gmail.com>2011-07-18 14:53:09 +0800
commitbfeb358622bde2d7bb872840bc28cd5b805549c9 (patch)
tree2f7482d0fb9e10e6de6bafbb4ac6fd75e973be16 /utils
parent192acabaf321f8233c9b252444abb1d93ca7a419 (diff)
downloadlibpinyin-bfeb358622bde2d7bb872840bc28cd5b805549c9.tar.gz
libpinyin-bfeb358622bde2d7bb872840bc28cd5b805549c9.tar.xz
libpinyin-bfeb358622bde2d7bb872840bc28cd5b805549c9.zip
temporarily work around ngseg
Diffstat (limited to 'utils')
-rw-r--r--utils/segment/ngseg.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/segment/ngseg.cpp b/utils/segment/ngseg.cpp
index 7bfc8c1..c4853df 100644
--- a/utils/segment/ngseg.cpp
+++ b/utils/segment/ngseg.cpp
@@ -67,7 +67,8 @@ bool deal_with_segmentable(GArray * current_utf16){
printf("\n");
#endif
g_phrase_lookup->convert_to_utf8(results, "\n", result_string);
- printf("%s\n", result_string);
+ if (result_string)
+ printf("%s\n", result_string);
g_array_free(results, TRUE);
g_free(result_string);
return true;