added extra debug level to attempted object registration that

exits with fatal error to help detection/debugging
This commit is contained in:
andy
2009-06-19 12:56:38 +01:00
parent 81e77b61d7
commit 6192d45253

View File

@ -138,10 +138,21 @@ bool Foam::regIOobject::checkIn()
// are created with the same name as their originating mesh
if (!registered_ && debug && name() != polyMesh::defaultRegion)
{
WarningIn("regIOobject::checkIn()")
<< "failed to register object " << objectPath()
if (debug == 2)
{
// Temporary: for ease of finding where checkin originates from.
FatalErrorIn("regIOobject::checkIn()")
<< "failed to register object " << objectPath()
<< " the name already exists in the objectRegistry"
<< endl;
<< abort(FatalError);
}
else
{
WarningIn("regIOobject::checkIn()")
<< "failed to register object " << objectPath()
<< " the name already exists in the objectRegistry"
<< endl;
}
}
}