diff --git a/src/foam/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C b/src/foam/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C index dd2533472..8e95a1873 100644 --- a/src/foam/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C +++ b/src/foam/meshes/polyMesh/polyBoundaryMesh/polyBoundaryMesh.C @@ -1026,12 +1026,14 @@ bool Foam::polyBoundaryMesh::writeData(Ostream& os) const os << patches.size() << nl << token::BEGIN_LIST << incrIndent << nl; + // Note: careful write: endl is not allowed because it flushes a stream + // HJ, 24/Oct/2018 forAll (patches, patchi) { os << indent << patches[patchi].name() << nl << indent << token::BEGIN_BLOCK << nl << incrIndent << patches[patchi] << decrIndent - << indent << token::END_BLOCK << endl; + << indent << token::END_BLOCK << nl; } os << decrIndent << token::END_LIST << endl; diff --git a/src/foam/meshes/polyMesh/polyMeshIO.C b/src/foam/meshes/polyMesh/polyMeshIO.C index 8ddd82799..cb11796e9 100644 --- a/src/foam/meshes/polyMesh/polyMeshIO.C +++ b/src/foam/meshes/polyMesh/polyMeshIO.C @@ -657,7 +657,8 @@ Foam::Ostream& Foam::operator<<(Ostream& os, const polyMesh& m) << m.boundaryMesh() << nl << m.pointZones() << nl << m.faceZones() << nl - << m.cellZones(); + << m.cellZones() << nl + << endl; return os; }