Fix invalid parsing of line with keyword end tag and comment

* Add error text when size differs
* #9845: Remove invalid parsing of data in comment line
The line '/ -- 123 123' was parsed incorrectly, and values 123 123 was added to the list of valid values for the keyword.
This commit is contained in:
Magne Sjaastad
2023-02-16 13:04:16 +01:00
committed by GitHub
parent 20439e1da9
commit edbeb4dfb1
5 changed files with 46 additions and 12 deletions

View File

@@ -42,7 +42,8 @@ class RifEclipseInputPropertyLoader
{
public:
static void createInputPropertiesFromKeywords( RigEclipseCaseData* eclipseCase,
const std::vector<RifEclipseKeywordContent>& keywordContent );
const std::vector<RifEclipseKeywordContent>& keywordContent,
QString* errorText );
// Returns map of assigned resultName and Eclipse Keyword.
static std::map<QString, QString> readProperties( const QString& fileName, RigEclipseCaseData* eclipseCase );
@@ -56,7 +57,8 @@ private:
static bool isInputPropertyCandidate( const RigEclipseCaseData* caseData,
const std::string& eclipseKeyword,
size_t numberOfValues );
size_t numberOfValues,
QString* errorText );
static bool appendNewInputPropertyResult( RigEclipseCaseData* caseData,
const QString& resultName,