File tree Expand file tree Collapse file tree 2 files changed +2
-5
lines changed
components/eamxx/src/share/io Expand file tree Collapse file tree 2 files changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -86,10 +86,6 @@ struct IOFileSpecs {
86
86
// If positive, flush the output file every these many snapshots
87
87
int flush_frequency = std::numeric_limits<int >::max();
88
88
89
- bool file_is_full () const {
90
- return storage.num_snapshots_in_file >=storage.max_snapshots_in_file ;
91
- }
92
-
93
89
bool file_needs_flush () const {
94
90
return storage.num_snapshots_in_file %flush_frequency==0 ;
95
91
}
Original file line number Diff line number Diff line change @@ -552,7 +552,8 @@ void OutputManager::run(const util::TimeStamp& timestamp)
552
552
}
553
553
554
554
// Check if we have hit the max number of snapshots and need to close the file
555
- if (filespecs.file_is_full ()) {
555
+ bool file_is_full = not filespecs.storage .snapshot_fits (m_output_control.next_write_ts );
556
+ if (file_is_full) {
556
557
release_file (filespecs.filename );
557
558
filespecs.close ();
558
559
}
You can’t perform that action at this time.
0 commit comments