]> git.donarmstrong.com Git - mothur.git/blobdiff - rarefact.cpp
changed int to pid_t type in fork(). roughed in get.mimarkscommand.
[mothur.git] / rarefact.cpp
index 0454d9e253473b368af34f35021dabbc4a50ae1b..83a6306db7568ac228fb110f1ad1c405cec9c7ec 100644 (file)
@@ -123,7 +123,7 @@ int Rarefact::createProcesses(vector<int>& procIters, RarefactionCurveData* rcd,
                
                //loop through and create all the processes you want
                while (process != processors) {
-                       int pid = fork();
+                       pid_t pid = fork();
                        
                        if (pid > 0) {
                                processIDS.push_back(pid);  //create map from line number to pid so you can append files in correct order later
@@ -133,7 +133,7 @@ int Rarefact::createProcesses(vector<int>& procIters, RarefactionCurveData* rcd,
                        
                                //pass numSeqs to parent
                                for(int i=0;i<displays.size();i++){
-                                       string tempFile = toString(getpid()) + toString(i) + ".rarefact.temp";
+                                       string tempFile = m->mothurGetpid(process) + toString(i) + ".rarefact.temp";
                                        displays[i]->outputTempFiles(tempFile);
                                }
                                exit(0);