polyMesh: Prevent readUpdate from setting write flags
A readUpdate should change face and point instances, but it should not set the mesh data to be written. Any mesh change as a result of readUpdate is the result of a read from disk, so it is not necessary for that change to be written out.
This commit is contained in:
@ -125,11 +125,6 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
|
||||
clearOut();
|
||||
|
||||
// Set instance to new instance. Note that points instance can differ
|
||||
// from from faces instance.
|
||||
setInstance(facesInst);
|
||||
points_.instance() = pointsInst;
|
||||
|
||||
points_ = pointIOField
|
||||
(
|
||||
IOobject
|
||||
@ -144,6 +139,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
)
|
||||
);
|
||||
|
||||
points_.instance() = pointsInst;
|
||||
|
||||
faces_ = faceCompactIOList
|
||||
(
|
||||
IOobject
|
||||
@ -158,6 +155,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
)
|
||||
);
|
||||
|
||||
faces_.instance() = facesInst;
|
||||
|
||||
owner_ = labelIOList
|
||||
(
|
||||
IOobject
|
||||
@ -172,6 +171,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
)
|
||||
);
|
||||
|
||||
owner_.instance() = facesInst;
|
||||
|
||||
neighbour_ = labelIOList
|
||||
(
|
||||
IOobject
|
||||
@ -186,6 +187,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
)
|
||||
);
|
||||
|
||||
neighbour_.instance() = facesInst;
|
||||
|
||||
// Reset the boundary patches
|
||||
polyBoundaryMesh newBoundary
|
||||
(
|
||||
@ -257,6 +260,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
}
|
||||
}
|
||||
|
||||
boundary_.instance() = facesInst;
|
||||
|
||||
|
||||
// Boundary is set so can use initMesh now (uses boundary_ to
|
||||
// determine internal and active faces)
|
||||
@ -338,6 +343,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
pointZones_.set(czI, newPointZones[czI].clone(pointZones_));
|
||||
}
|
||||
|
||||
pointZones_.instance() = facesInst;
|
||||
|
||||
|
||||
meshFaceZones newFaceZones
|
||||
(
|
||||
@ -379,6 +386,8 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
faceZones_.set(fzI, newFaceZones[fzI].clone(faceZones_));
|
||||
}
|
||||
|
||||
faceZones_.instance() = facesInst;
|
||||
|
||||
|
||||
meshCellZones newCellZones
|
||||
(
|
||||
@ -416,6 +425,9 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
cellZones_.set(czI, newCellZones[czI].clone(cellZones_));
|
||||
}
|
||||
|
||||
cellZones_.instance() = facesInst;
|
||||
|
||||
|
||||
// Re-read tet base points
|
||||
tetBasePtIsPtr_ = readTetBasePtIs();
|
||||
|
||||
@ -469,6 +481,7 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||
}
|
||||
|
||||
points_.transfer(newPoints);
|
||||
|
||||
points_.instance() = pointsInst;
|
||||
|
||||
// Re-read tet base points
|
||||
|
||||
Reference in New Issue
Block a user