functionObjectList: Prevent execution during construction
As of 2ebed5ec, functonObjectList::start contains run commands that
trigger if some function objects are executable at time-zero. A call to
this method in functionObjectList::New has been removed (and replaced
with functonObjectList::read) as it was causing postProcess and <solver>
-postProcess to execute twice; once on construction, and once at the
selected initial time.
This change also fixes lookup errors generated by postProcess which
occured because fields (specified with -field or -fields arguments) are
not read and registered prior to function object construction.
Usage of functonObjectList::start within Time::run has not been altered.
This commit is contained in:
@ -540,7 +540,7 @@ Foam::autoPtr<Foam::functionObjectList> Foam::functionObjectList::New
|
||||
functionsPtr.reset(new functionObjectList(runTime));
|
||||
}
|
||||
|
||||
functionsPtr->start();
|
||||
functionsPtr->read();
|
||||
|
||||
return functionsPtr;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user