]> git.donarmstrong.com Git - mothur.git/blobdiff - phylodiversitycommand.cpp
chimera.slayer fix
[mothur.git] / phylodiversitycommand.cpp
index 1c90eca1180acc6287b0530e9c9d3e84fbea120d..a97e09564d6cbf27d67b57fa461469096237f354 100644 (file)
@@ -24,6 +24,7 @@ vector<string> PhyloDiversityCommand::getValidParameters(){
 //**********************************************************************************************************************
 PhyloDiversityCommand::PhyloDiversityCommand(){        
        try {
+               abort = true;
                //initialize outputTypes
                vector<string> tempOutNames;
                outputTypes["phylodiv"] = tempOutNames;
@@ -321,7 +322,11 @@ int PhyloDiversityCommand::createProcesses(vector<int>& procIters, Tree* t, map<
                                out.close();
                                
                                exit(0);
-                       }else { m->mothurOut("unable to spawn the necessary processes."); m->mothurOutEndLine(); exit(0); }
+                       }else { 
+                               m->mothurOut("[ERROR]: unable to spawn the necessary processes."); m->mothurOutEndLine(); 
+                               for (int i = 0; i < processIDS.size(); i++) { kill (processIDS[i], SIGINT); }
+                               exit(0);
+                       }
                }
                
                driver(t, div, sumDiv, procIters[0], increment, randomLeaf, numSampledList, outCollect, outSum, true);