functionObjects::timeActivatedFileUpdate: Copy file then move
Patch contributed by Mattijs Janssens Resolves bug-report http://bugs.openfoam.org/view.php?id=2324
This commit is contained in:
parent
146f7e6bea
commit
b2d5dca488
1 changed files with 3 additions and 1 deletions
|
|
@ -65,7 +65,9 @@ void Foam::functionObjects::timeActivatedFileUpdate::updateFile()
|
|||
Info<< nl << type() << ": copying file" << nl << timeVsFile_[i].second()
|
||||
<< nl << "to:" << nl << fileToUpdate_ << nl << endl;
|
||||
|
||||
cp(timeVsFile_[i].second(), fileToUpdate_);
|
||||
fileName destFile(fileToUpdate_ + Foam::name(pid()));
|
||||
cp(timeVsFile_[i].second(), destFile);
|
||||
mv(destFile, fileToUpdate_);
|
||||
lastIndex_ = i;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue