summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--decoder/tree2string_translator.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/decoder/tree2string_translator.cc b/decoder/tree2string_translator.cc
index 6966ccf8..6f65658e 100644
--- a/decoder/tree2string_translator.cc
+++ b/decoder/tree2string_translator.cc
@@ -214,7 +214,7 @@ struct Tree2StringTranslatorImpl {
// the following takes care of them
vector<bool> prune(hg.edges_.size(), false);
hg.PruneEdges(prune, true);
-
+ if (hg.edges_.size() == 0) return false;
//hg.PrintGraphviz();
minus_lm_forest->swap(hg);
return true;