]> git.donarmstrong.com Git - mothur.git/blobdiff - clustersplitcommand.cpp
finished wrapper for catchall
[mothur.git] / clustersplitcommand.cpp
index 3c957a6ce84b5e5a489faaccf18a1dc40f99a02b..85a183aca409f65e3cb0e605d5ae777d10efe665 100644 (file)
@@ -31,6 +31,7 @@ vector<string> ClusterSplitCommand::getValidParameters(){
 //**********************************************************************************************************************
 ClusterSplitCommand::ClusterSplitCommand(){    
        try {
+               abort = true;
                //initialize outputTypes
                vector<string> tempOutNames;
                outputTypes["list"] = tempOutNames;
@@ -884,7 +885,11 @@ int ClusterSplitCommand::createProcesses(vector < vector < map<string, string> >
                                outLabels.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);
+                       }
                }
                
                //force parent to wait until all the processes are done