X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=prcseqscommand.cpp;h=c4416b34bf6c8adc444c2292fc03fd140d0b5d0a;hb=60928795782d8f8648ec373d6a96b53032a77429;hp=6a4df6388683b1cda6aa5aa41d1ec3d2d672a15f;hpb=cbbf2f185fc7289910bb69421095c1de024c5225;p=mothur.git diff --git a/prcseqscommand.cpp b/prcseqscommand.cpp index 6a4df63..c4416b3 100644 --- a/prcseqscommand.cpp +++ b/prcseqscommand.cpp @@ -442,12 +442,12 @@ int PcrSeqsCommand::createProcesses(string filename, string goodFileName, string processIDS.push_back(pid); //create map from line number to pid so you can append files in correct order later process++; }else if (pid == 0){ - string locationsFile = toString(getpid()) + ".temp"; - num = driverPcr(filename, goodFileName + toString(getpid()) + ".temp", badFileName + toString(getpid()) + ".temp", locationsFile, badSeqNames, lines[process], pstart, adjustNeeded); + string locationsFile = m->mothurGetpid(process) + ".temp"; + num = driverPcr(filename, goodFileName + m->mothurGetpid(process) + ".temp", badFileName + m->mothurGetpid(process) + ".temp", locationsFile, badSeqNames, lines[process], pstart, adjustNeeded); //pass numSeqs to parent ofstream out; - string tempFile = filename + toString(getpid()) + ".num.temp"; + string tempFile = filename + m->mothurGetpid(process) + ".num.temp"; m->openOutputFile(tempFile, out); out << pstart << '\t' << adjustNeeded << endl; out << num << '\t' << badSeqNames.size() << endl; @@ -464,7 +464,7 @@ int PcrSeqsCommand::createProcesses(string filename, string goodFileName, string } } - string locationsFile = toString(getpid()) + ".temp"; + string locationsFile = m->mothurGetpid(process) + ".temp"; num = driverPcr(filename, goodFileName, badFileName, locationsFile, badSeqNames, lines[0], pstart, adjustNeeded); //force parent to wait until all the processes are done