Skip to content

Commit

Permalink
create_program_address can return error
Browse files Browse the repository at this point in the history
If the calculated address is on curve, it would return an error.
  • Loading branch information
Xeonacid authored Sep 23, 2024
1 parent 26f9fcb commit 9a6654c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/pubkey/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ impl Pubkey {
///
pub fn create_program_address(seeds: Vec<&[u8]>, program_id: &Self) -> Self {
PubkeyOriginal::create_program_address(&seeds, &program_id.0)
.expect("Failed to create program address. This is extremely unlikely.")
.expect("Failed to create program address. Is the bump valid?")
.into()
}

Expand Down

0 comments on commit 9a6654c

Please sign in to comment.