]> git.donarmstrong.com Git - mothur.git/blobdiff - trimflowscommand.cpp
rewrote metastats command in c++, added mothurRemove function to handle ~ error....
[mothur.git] / trimflowscommand.cpp
index ec043360ad1cd553d782d1d67ab531c9a4610778..d17e000e9ce3a2d36f6a432f8647e99b7f58549f 100644 (file)
@@ -270,7 +270,7 @@ int TrimFlowsCommand::execute(){
                                        }
 
                                        if(size < 10){
-                                               remove(barcodePrimerComboFileNames[i][j].c_str());
+                                               m->mothurRemove(barcodePrimerComboFileNames[i][j]);
                                        }
                                        else{
                                                output << barcodePrimerComboFileNames[i][j] << endl;
@@ -1058,23 +1058,23 @@ int TrimFlowsCommand::createProcessesCreateTrim(string flowFileName, string trim
                        m->mothurOut("Appending files from process " + toString(processIDS[i])); m->mothurOutEndLine();
                        
                        m->appendFiles((trimFlowFileName + toString(processIDS[i]) + ".temp"), trimFlowFileName);
-                       remove((trimFlowFileName + toString(processIDS[i]) + ".temp").c_str());
+                       m->mothurRemove((trimFlowFileName + toString(processIDS[i]) + ".temp"));
 //                     m->mothurOut("\tDone with trim.flow file"); m->mothurOutEndLine();
 
                        m->appendFiles((scrapFlowFileName + toString(processIDS[i]) + ".temp"), scrapFlowFileName);
-                       remove((scrapFlowFileName + toString(processIDS[i]) + ".temp").c_str());
+                       m->mothurRemove((scrapFlowFileName + toString(processIDS[i]) + ".temp"));
 //                     m->mothurOut("\tDone with scrap.flow file"); m->mothurOutEndLine();
 
                        if(fasta){
                                m->appendFiles((fastaFileName + toString(processIDS[i]) + ".temp"), fastaFileName);
-                               remove((fastaFileName + toString(processIDS[i]) + ".temp").c_str());
+                               m->mothurRemove((fastaFileName + toString(processIDS[i]) + ".temp"));
 //                             m->mothurOut("\tDone with flow.fasta file"); m->mothurOutEndLine();
                        }
                        if(allFiles){                                           
                                for (int j = 0; j < barcodePrimerComboFileNames.size(); j++) {
                                        for (int k = 0; k < barcodePrimerComboFileNames[0].size(); k++) {
                                                m->appendFiles((barcodePrimerComboFileNames[j][k] + toString(processIDS[i]) + ".temp"), barcodePrimerComboFileNames[j][k]);
-                                               remove((barcodePrimerComboFileNames[j][k] + toString(processIDS[i]) + ".temp").c_str());
+                                               m->mothurRemove((barcodePrimerComboFileNames[j][k] + toString(processIDS[i]) + ".temp"));
                                        }
                                }
                        }