mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
BUG: rigidBodyMeshMotion: do not access uninitialised. Fixes #2127
This commit is contained in:
@ -260,7 +260,11 @@ void Foam::rigidBodyMeshMotion::solve()
|
||||
ramp*t.lookupObject<uniformDimensionedVectorField>("g").value();
|
||||
}
|
||||
|
||||
vector oldPos = model_.cCofR(bodyIdCofG_);
|
||||
vector oldPos(vector::uniform(GREAT));
|
||||
if (bodyIdCofG_ != -1)
|
||||
{
|
||||
oldPos = model_.cCofR(bodyIdCofG_);
|
||||
}
|
||||
|
||||
if (test_)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user