diff --git a/src/parallel/decompose/decompositionMethods/decompositionMethod/decompositionMethod.C b/src/parallel/decompose/decompositionMethods/decompositionMethod/decompositionMethod.C index 39b20189b9..3e36955fde 100644 --- a/src/parallel/decompose/decompositionMethods/decompositionMethod/decompositionMethod.C +++ b/src/parallel/decompose/decompositionMethods/decompositionMethod/decompositionMethod.C @@ -289,16 +289,25 @@ void Foam::decompositionMethod::calcCSR forAll(pbm, patchI) { - if (isA(pbm[patchI])) + if + ( + isA(pbm[patchI]) + && refCast(pbm[patchI]).owner() + ) { - const unallocLabelList& faceCells = pbm[patchI].faceCells(); + const cyclicPolyPatch& cycPatch = refCast + ( + pbm[patchI] + ); - label sizeby2 = faceCells.size()/2; + const unallocLabelList& faceCells = cycPatch.faceCells(); + const unallocLabelList& nbrCells = + cycPatch.neighbPatch().faceCells(); - for (label faceI=0; faceI