Skip to content

Commit

Permalink
Removes set_no_remove_on_drop() from AppendVec/AccountsFile
Browse files Browse the repository at this point in the history
  • Loading branch information
brooksprumo committed Aug 7, 2023
1 parent d2dace4 commit d7fda30
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
9 changes: 0 additions & 9 deletions runtime/src/accounts_file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,15 +58,6 @@ impl AccountsFile {
Ok((Self::AppendVec(av), num_accounts))
}

/// By default, all AccountsFile will remove its underlying file on
/// drop. Calling this function to disable such behavior for this
/// instance.
pub fn set_no_remove_on_drop(&mut self) {
match self {
Self::AppendVec(av) => av.set_no_remove_on_drop(),
}
}

pub fn flush(&self) -> Result<()> {
match self {
Self::AppendVec(av) => av.flush(),
Expand Down
4 changes: 0 additions & 4 deletions runtime/src/append_vec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -292,10 +292,6 @@ impl AppendVec {
}
}

pub fn set_no_remove_on_drop(&mut self) {
// noop: will be removed next
}

fn sanitize_len_and_size(current_len: usize, file_size: usize) -> Result<()> {
if file_size == 0 {
Err(AccountsFileError::AppendVecError(
Expand Down

0 comments on commit d7fda30

Please sign in to comment.