diff --git a/src/OpenFOAM/global/debug/debug.C b/src/OpenFOAM/global/debug/debug.C index f8f513322c6d821cd5e39b7721cbfd57da2d770a..479c56db0e8787e583b92c80e865086921ea043d 100644 --- a/src/OpenFOAM/global/debug/debug.C +++ b/src/OpenFOAM/global/debug/debug.C @@ -95,10 +95,18 @@ Foam::dictionary& Foam::debug::controlDict() controlDictPtr_ = new dictionary(); forAllReverse(controlDictFiles, cdfi) { - controlDictPtr_->merge - ( - dictionary(IFstream(controlDictFiles[cdfi])()) - ); + IFstream ifs(controlDictFiles[cdfi]); + + if (!ifs.good()) + { + SafeFatalIOErrorIn + ( + "debug::controlDict()", + ifs, + "Cannot open controlDict" + ); + } + controlDictPtr_->merge(dictionary(ifs)); } } diff --git a/src/sampling/sampledSet/sampledSets/sampledSets.C b/src/sampling/sampledSet/sampledSets/sampledSets.C index 803190a4a197337af6907b42681de15a69947eae..44ea1691af47a20f24ad05e298073eb3591f9acd 100644 --- a/src/sampling/sampledSet/sampledSets/sampledSets.C +++ b/src/sampling/sampledSet/sampledSets/sampledSets.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -282,10 +282,6 @@ void Foam::sampledSets::correct() bool setsFound = dict_.found("sets"); if (setsFound) { - // reset interpolation - pointMesh::Delete(mesh_); - volPointInterpolation::Delete(mesh_); - searchEngine_.correct(); PtrList<sampledSet> newList