Fixed warning on existing links

This commit is contained in:
Hrvoje Jasak 2011-03-14 14:14:46 +00:00
parent a180a291f4
commit a6740cffd2

View file

@ -880,17 +880,20 @@ int main(int argc, char *argv[])
}
else
{
// link with relative paths
// Link with relative paths
const string parentPath = string("..")/"..";
fileName currentDir(cwd());
chDir(timePath);
ln
(
parentPath/runTime.timeName()/uniformDir,
uniformDir
);
chDir(currentDir);
if (!exists(parentPath/runTime.timeName()/uniformDir))
{
ln
(
parentPath/runTime.timeName()/uniformDir,
uniformDir
);
chDir(currentDir);
}
}
}
}