Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Commit

Permalink
AccountsPackage::new less brittle (#23968)
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffwashington authored Mar 30, 2022
1 parent 3749765 commit 82c5230
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion runtime/src/snapshot_package.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,11 @@ impl AccountsPackage {
.path()
.join(bank_snapshot_info.slot.to_string());
fs::create_dir_all(&snapshot_hardlink_dir)?;
let file_name =
snapshot_utils::path_to_file_name_str(&bank_snapshot_info.snapshot_path)?;
fs::hard_link(
&bank_snapshot_info.snapshot_path,
&snapshot_hardlink_dir.join(bank_snapshot_info.slot.to_string()),
&snapshot_hardlink_dir.join(file_name),
)?;
}

Expand Down

0 comments on commit 82c5230

Please sign in to comment.