]> git.donarmstrong.com Git - mothur.git/blobdiff - parsimony.cpp
added checks for ^C to quit command instead of program
[mothur.git] / parsimony.cpp
index 16c7748e76a50337df471e414543ac982a19a6b0..0487822764bbf36e11da5bd8faada1bba34a63c4 100644 (file)
@@ -49,6 +49,9 @@ EstOutput Parsimony::getValues(Tree* t) {
                                }
                
                                for(int i=copyTree->getNumLeaves();i<copyTree->getNumNodes();i++){
+                               
+                                       if (m->control_pressed) { return data; }
+                                       
                                        int lc = copyTree->tree[i].getLChild();
                                        int rc = copyTree->tree[i].getRChild();
                        
@@ -97,6 +100,9 @@ EstOutput Parsimony::getValues(Tree* t) {
 //                     map<string,int>::iterator it;
                        
                        for(int i=copyTree->getNumLeaves();i<copyTree->getNumNodes();i++){
+                       
+                               if (m->control_pressed) { return data; }
+                               
                                int lc = copyTree->tree[i].getLChild();
                                int rc = copyTree->tree[i].getRChild();