BUG: regIOobject : fix error message for files that cannot be found

This commit is contained in:
mattijs
2010-06-07 16:45:24 +01:00
parent e5e768403b
commit 0ebfd35059

View File

@ -61,7 +61,21 @@ Foam::Istream& Foam::regIOobject::readStream()
}
else
{
// Search intelligently for file
objPath = filePath();
if (!objPath.size())
{
FatalIOError
(
"regIOobject::readStream()",
__FILE__,
__LINE__,
objectPath(),
0
) << "cannot find file"
<< exit(FatalIOError);
}
}
if (!(isPtr_ = objectStream(objPath)))