mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Updated ERT to 315ceeee250808ea6a6530233dd5125f9f76f06c
Support of reading LGR dimensions Close file handles between access to files, keep ERT file-related cache to speed up reading of many files multiple times p4#: 21477
This commit is contained in:
@@ -208,14 +208,7 @@ RifReaderEclipseOutput::RifReaderEclipseOutput()
|
||||
RifReaderEclipseOutput::~RifReaderEclipseOutput()
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
/// Close interface (for now, no files are kept open after calling methods, so just clear members)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RifReaderEclipseOutput::close()
|
||||
{
|
||||
if (m_ecl_init_file)
|
||||
{
|
||||
ecl_file_close(m_ecl_init_file);
|
||||
@@ -226,6 +219,15 @@ void RifReaderEclipseOutput::close()
|
||||
{
|
||||
m_dynamicResultsAccess->close();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
/// Close interface (for now, no files are kept open after calling methods, so just clear members)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RifReaderEclipseOutput::close()
|
||||
{
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -442,7 +444,7 @@ bool RifReaderEclipseOutput::readActiveCellInfo()
|
||||
QString egridFileName = RifEclipseOutputFileTools::firstFileNameOfType(m_filesWithSameBaseName, ECL_EGRID_FILE);
|
||||
if (egridFileName.size() > 0)
|
||||
{
|
||||
ecl_file_type* ecl_file = ecl_file_open(egridFileName.toAscii().data());
|
||||
ecl_file_type* ecl_file = ecl_file_open(egridFileName.toAscii().data(), ECL_FILE_CLOSE_STREAM);
|
||||
if (!ecl_file) return false;
|
||||
|
||||
int actnumKeywordCount = ecl_file_get_num_named_kw(ecl_file, ACTNUM_KW);
|
||||
@@ -1010,7 +1012,7 @@ void RifReaderEclipseOutput::openInitFile()
|
||||
QString initFileName = RifEclipseOutputFileTools::firstFileNameOfType(m_filesWithSameBaseName, ECL_INIT_FILE);
|
||||
if (initFileName.size() > 0)
|
||||
{
|
||||
m_ecl_init_file = ecl_file_open(initFileName.toAscii().data());
|
||||
m_ecl_init_file = ecl_file_open(initFileName.toAscii().data(), ECL_FILE_CLOSE_STREAM);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user