X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FMEDPartitioner%2FMEDPARTITIONER_MEDPartitioner.cxx;h=6ea40a0e6a931d31e57ba4008dbe8fae12c3b138;hb=14f30db13a9749dd4a47f5c14944c7331e7390d1;hp=c97c36b03407b7ca459677ef0ca055638c0047f5;hpb=1e36a6710aab710674e20fbd89f6a9a8f238c023;p=tools%2Fmedcoupling.git diff --git a/src/MEDPartitioner/MEDPARTITIONER_MEDPartitioner.cxx b/src/MEDPartitioner/MEDPARTITIONER_MEDPartitioner.cxx index c97c36b03..6ea40a0e6 100644 --- a/src/MEDPartitioner/MEDPARTITIONER_MEDPartitioner.cxx +++ b/src/MEDPartitioner/MEDPARTITIONER_MEDPartitioner.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -24,8 +24,12 @@ #include "MEDPARTITIONER_ParallelTopology.hxx" #include "MEDPARTITIONER_Utils.hxx" #include "MEDPARTITIONER_Graph.hxx" -#include "MEDPARTITIONER_MetisGraph.hxx" -#include "MEDPARTITIONER_ScotchGraph.hxx" +#ifdef MED_ENABLE_METIS +# include "MEDPARTITIONER_MetisGraph.hxx" +#endif +#ifdef MED_ENABLE_SCOTCH +# include "MEDPARTITIONER_ScotchGraph.hxx" +#endif #include "MEDPARTITIONER_MeshCollectionDriver.hxx" #include "MEDCouplingUMesh.hxx" @@ -136,7 +140,8 @@ MEDCoupling::MEDFileData* MEDPARTITIONER::MEDPartitioner::getMEDFileData() MEDPARTITIONER::Graph* MEDPARTITIONER::MEDPartitioner::Graph(MEDCoupling::MEDCouplingSkyLineArray* graph, Graph::splitter_type split, int* edgeweight) { MEDPARTITIONER::Graph* cellGraph=0; - MEDCoupling::MEDCouplingSkyLineArray* arr = new MEDCoupling::MEDCouplingSkyLineArray(graph->getIndexArray(), graph->getValueArray()); + // will be destroyed by XXXGraph class: + MEDCoupling::MEDCouplingSkyLineArray* arr = MEDCoupling::MEDCouplingSkyLineArray::New(graph->getIndexArray(), graph->getValuesArray()); switch (split) { case Graph::METIS: