diff data/model/Model.cpp @ 1020:9c00e7944bf2

Merge
author Chris Cannam
date Thu, 27 Nov 2014 17:51:21 +0000
parents 4a2c150ecd67
children cc27f35aa75c
line wrap: on
line diff
--- a/data/model/Model.cpp	Thu Nov 27 17:50:34 2014 +0000
+++ b/data/model/Model.cpp	Thu Nov 27 17:51:21 2014 +0000
@@ -85,9 +85,13 @@
         m_alignment->aboutToDelete();
         delete m_alignment;
     }
+    
     m_alignment = alignment;
-    connect(m_alignment, SIGNAL(completionChanged()),
-            this, SIGNAL(alignmentCompletionChanged()));
+
+    if (m_alignment) {
+        connect(m_alignment, SIGNAL(completionChanged()),
+                this, SIGNAL(alignmentCompletionChanged()));
+    }
 }
 
 const AlignmentModel *