Makes CollectDataToIORank::localIndexMap_ have nonzero size when accessing.

While it may not produce memory errors it is semantically wrong to insert
entries with random acces into a vector that has reserved enough memory to
hold the values but still has size 0.
This commit is contained in:
Markus Blatt
2017-01-18 11:10:31 +01:00
parent feb1687e45
commit 0aa4b668a9
+1 -1
View File
@@ -223,7 +223,7 @@ namespace Ewoms
localIndexMap_.clear();
const size_t gridSize = gridManager.grid().size( 0 );
localIndexMap_.reserve( gridSize );
localIndexMap_.resize( gridSize, -1 );
// store the local Cartesian index
IndexMapType distributedCartesianIndex;