Commit fd2ac09c authored by Henry Weller's avatar Henry Weller
Browse files

mapFields: reset the FOAM_CASE environment variable

Patch proveded by Alexey Matveichev
Resolves bug-report http://bugs.openfoam.org/view.php?id=2229
parent 91c8c053
Info<< "\nCreate databases as time" << endl;
const auto caseDirOrig = getEnv("FOAM_CASE");
const auto caseNameOrig = getEnv("FOAM_CASE_NAME");
setEnv("FOAM_CASE", rootDirSource/caseDirSource, true);
setEnv("FOAM_CASE_NAME", caseDirSource, true);
Time runTimeSource
(
Time::controlDictName,
rootDirSource,
caseDirSource
);
setEnv("FOAM_CASE", caseDirOrig, true);
setEnv("FOAM_CASE_NAME", caseNameOrig, true);
Time runTimeTarget
(
......
......@@ -236,8 +236,8 @@ int main(int argc, char *argv[])
fileName rootDirTarget(args.rootPath());
fileName caseDirTarget(args.globalCaseName());
const fileName casePath = args[1];
const fileName rootDirSource = casePath.path();
fileName casePath = args[1];
const fileName rootDirSource = casePath.path().toAbsolute();
const fileName caseDirSource = casePath.name();
Info<< "Source: " << rootDirSource << " " << caseDirSource << endl;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment