mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
INP reader: fix incorrect zero element for line shift.
This commit is contained in:
committed by
jonjenssen
parent
58bf235d5a
commit
2beb830102
@@ -318,8 +318,13 @@ std::vector<size_t> RifInpReader::readElementSet( std::istream& stream )
|
||||
auto parts = RiaStdStringTools::splitString( line, ',' );
|
||||
for ( auto part : parts )
|
||||
{
|
||||
int elementId = RiaStdStringTools::toInt( part ) - 1;
|
||||
elementSet.push_back( elementId );
|
||||
std::string trimmedPart = RiaStdStringTools::trimString( part );
|
||||
|
||||
if ( !trimmedPart.empty() )
|
||||
{
|
||||
int elementId = RiaStdStringTools::toInt( trimmedPart ) - 1;
|
||||
elementSet.push_back( elementId );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user