Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix program runtime environment of loader-v4.
Browse files Browse the repository at this point in the history
Lichtso committed Nov 14, 2024
1 parent c8fd486 commit 130dfae
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions svm/src/program_loader.rs
Original file line number Diff line number Diff line change
@@ -191,18 +191,14 @@ pub fn load_program_with_pubkey<CB: TransactionProcessingCallback>(
&loader_v4::id(),
program_account.data().len(),
slot,
environments.program_runtime_v2.clone(),
environments.program_runtime_v1.clone(),
reload,
)
})
.map_err(|_| (slot, ProgramCacheEntryOwner::LoaderV4)),
}
.unwrap_or_else(|(slot, owner)| {
let env = if let ProgramCacheEntryOwner::LoaderV4 = &owner {
environments.program_runtime_v2.clone()
} else {
environments.program_runtime_v1.clone()
};
let env = environments.program_runtime_v1.clone();
ProgramCacheEntry::new_tombstone(
slot,
owner,

0 comments on commit 130dfae

Please sign in to comment.