refactor: Add AutoFile::size
This commit is contained in:
5 files changed
+24
-6
No files matched your search
@@ -544,8 +544,7 @@ void BerkeleyRODatabase::Open()
|
||||
page_size = outer_meta.pagesize;
|
||||
|
||||
// Verify the size of the file is a multiple of the page size
|
||||
db_file.seek(0, SEEK_END);
|
||||
int64_t size = db_file.tell();
|
||||
const int64_t size{db_file.size()};
|
||||
|
||||
// Since BDB stores everything in a page, the file size should be a multiple of the page size;
|
||||
// However, BDB doesn't actually check that this is the case, and enforcing this check results
|
||||
|
||||
Reference in new issue
Block a user