diff --git a/contrib/other-builds/mert_lib/.cproject b/contrib/other-builds/mert_lib/.cproject
index 41a471cd1..79dffb294 100644
--- a/contrib/other-builds/mert_lib/.cproject
+++ b/contrib/other-builds/mert_lib/.cproject
@@ -7,7 +7,7 @@
-
+
@@ -23,13 +23,14 @@
-
+
@@ -45,11 +46,11 @@
-
-
+
+
-
+
@@ -61,7 +62,7 @@
-
+
@@ -119,5 +120,13 @@
-
+
+
+
+
+
+
+
+
+
diff --git a/moses-chart-cmd/IOWrapper.cpp b/moses-chart-cmd/IOWrapper.cpp
index d0ef97c42..b65873881 100644
--- a/moses-chart-cmd/IOWrapper.cpp
+++ b/moses-chart-cmd/IOWrapper.cpp
@@ -723,14 +723,16 @@ void IOWrapper::OutputAlignment(size_t translationId , const Moses::ChartHypothe
{
ostringstream out;
- Alignments retAlign;
- OutputAlignment(retAlign, hypo, 0);
+ if (hypo) {
+ Alignments retAlign;
+ OutputAlignment(retAlign, hypo, 0);
- // output alignments
- Alignments::const_iterator iter;
- for (iter = retAlign.begin(); iter != retAlign.end(); ++iter) {
- const pair &alignPoint = *iter;
- out << alignPoint.first << "-" << alignPoint.second << " ";
+ // output alignments
+ Alignments::const_iterator iter;
+ for (iter = retAlign.begin(); iter != retAlign.end(); ++iter) {
+ const pair &alignPoint = *iter;
+ out << alignPoint.first << "-" << alignPoint.second << " ";
+ }
}
out << endl;