functionObjectList: Set parent dictionary for temporary function dictionary

so that it inherits the IO properties of the top dictionary.

Resolves bug-report https://bugs.openfoam.org/view.php?id=3414
This commit is contained in:
Henry Weller
2019-12-19 16:47:23 +00:00
parent a9ddd758e8
commit 2ef9267323

View File

@ -322,7 +322,7 @@ bool Foam::functionObjectList::readFunctionObject
// Delay processing the functionEntries // Delay processing the functionEntries
// until after the function argument entries have been added // until after the function argument entries have been added
entry::disableFunctionEntries = true; entry::disableFunctionEntries = true;
dictionary funcsDict(fileStream); dictionary funcsDict(funcName, functionsDict, fileStream);
entry::disableFunctionEntries = false; entry::disableFunctionEntries = false;
dictionary* funcDictPtr = &funcsDict; dictionary* funcDictPtr = &funcsDict;
@ -389,7 +389,12 @@ bool Foam::functionObjectList::readFunctionObject
{ {
OStringStream os; OStringStream os;
funcArgsDict.write(os); funcArgsDict.write(os);
funcArgsDict = dictionary(IStringStream(os.str())()); funcArgsDict = dictionary
(
funcName,
functionsDict,
IStringStream(os.str())()
);
} }
checkUnsetEntries(funcCall, funcArgsDict, funcDict0, context); checkUnsetEntries(funcCall, funcArgsDict, funcDict0, context);