diff --git a/applications/utilities/mesh/manipulation/mergeMeshes/mergePolyMesh.C b/applications/utilities/mesh/manipulation/mergeMeshes/mergePolyMesh.C index 0335cf3abc..bcd1c5c9ce 100644 --- a/applications/utilities/mesh/manipulation/mergeMeshes/mergePolyMesh.C +++ b/applications/utilities/mesh/manipulation/mergeMeshes/mergePolyMesh.C @@ -275,6 +275,12 @@ void Foam::mergePolyMesh::addMesh(const polyMesh& m) patchIndices[patchI] = patchIndex(bm[patchI]); } + // Temporary: update number of allowable patches. This should be + // determined at the top - before adding anything. + meshMod_.setNumPatches(patchNames_.size()); + + + const faceZoneMesh& fz = m.faceZones(); labelList faceZoneIndices(fz.size());