Salome HOME
Avoid useless time stamp incrementation
authorAnthony Geay <anthony.geay@edf.fr>
Sun, 10 May 2020 21:40:10 +0000 (23:40 +0200)
committerAnthony Geay <anthony.geay@edf.fr>
Sun, 10 May 2020 21:40:10 +0000 (23:40 +0200)
src/MEDCoupling/MEDCouplingMemArray.hxx
src/MEDCoupling/MEDCouplingUMesh.cxx

index dd2b5f15377413f06cf5761e0e2137eb85ea4cde..ba49d508476d757d1fcb6bb943b4f7cd37c668bc 100755 (executable)
@@ -261,7 +261,8 @@ namespace MEDCoupling
     T getIJ(std::size_t tupleId, std::size_t compoId) const { return _mem[tupleId*_info_on_compo.size()+compoId]; }
     void setIJ(std::size_t tupleId, std::size_t compoId, T newVal) { _mem[tupleId*_info_on_compo.size()+compoId]=newVal; declareAsNew(); }
     void setIJSilent(std::size_t tupleId, std::size_t compoId, T newVal) { _mem[tupleId*_info_on_compo.size()+compoId]=newVal; }
-    T *getPointer() { return _mem.getPointer(); declareAsNew(); }
+    T *getPointer() { declareAsNew(); return getPointerSilent(); }
+    T *getPointerSilent() { return _mem.getPointer(); }
     void pack() const;
     bool isAllocated() const override;
     void checkAllocated() const;
index 14c2e2b19cc8d12e6d446545cb226e629ff71785..c22552bae39dff82cae00b8db7b5903495102537 100755 (executable)
@@ -1797,7 +1797,7 @@ void MEDCouplingUMesh::FindCommonCellsAlg(int compType, mcIdType startCellId, co
                     {
                       mcIdType newPos(commonCells->getNumberOfTuples());
                       mcIdType pos(commonCellsI->back());
-                      std::sort(commonCells->getPointer()+pos,commonCells->getPointer()+newPos);
+                      std::sort(commonCells->getPointerSilent()+pos,commonCells->getPointerSilent()+newPos);
                       commonCellsI->pushBackSilent(newPos);
                       for(const mcIdType *it=commonCells->begin()+pos;it!=commonCells->end();it++)
                         isFetched[*it]=true;