From 84c37cf72648b0e92599139a170e2f72b5f9519c Mon Sep 17 00:00:00 2001 From: Christophe Geuzaine <cgeuzaine@ulg.ac.be> Date: Wed, 28 Oct 2009 13:37:12 +0000 Subject: [PATCH] fix msvc compile --- Mesh/meshPartition.cpp | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/Mesh/meshPartition.cpp b/Mesh/meshPartition.cpp index 0ff65909b0..627bcd28c4 100644 --- a/Mesh/meshPartition.cpp +++ b/Mesh/meshPartition.cpp @@ -101,17 +101,16 @@ void MakeGraphDIM(const EntIter begin, const EntIter end, ******************************************************************************/ int PartitionMeshFace( std::list<GFace*> &cFaces, meshPartitionOptions &options) { - - GModel *tmp_model = new GModel(); - for(std::list<GFace*>::iterator it = cFaces.begin(); it != cFaces.end(); it++) - tmp_model->add(*it); - - PartitionMesh(tmp_model,options); - - for(std::list<GFace*>::iterator it = cFaces.begin(); it != cFaces.end(); it++) - tmp_model->remove(*it); - delete tmp_model; - + GModel *tmp_model = new GModel(); + for(std::list<GFace*>::iterator it = cFaces.begin(); it != cFaces.end(); it++) + tmp_model->add(*it); + + PartitionMesh(tmp_model,options); + + for(std::list<GFace*>::iterator it = cFaces.begin(); it != cFaces.end(); it++) + tmp_model->remove(*it); + delete tmp_model; + return 1; } int PartitionMesh(GModel *const model, meshPartitionOptions &options) -- GitLab