Enable program upgrades via CPI (#14449) (#14469)

(cherry picked from commit 5eacc5d08d)

Co-authored-by: Jack May <jack@solana.com>
This commit is contained in:
mergify[bot]
2021-01-06 23:45:10 +00:00
committed by GitHub
parent 49aca9ecd8
commit 0fbdc7e152
3 changed files with 93 additions and 5 deletions

View File

@@ -172,6 +172,10 @@ pub fn upgrade(
)
}
pub fn is_upgrade_instruction(instruction_data: &[u8]) -> bool {
3 == instruction_data[0]
}
/// Returns the instructions required to set a program's authority.
pub fn set_authority(
program_address: &Pubkey,