Fix authority in bpf_loader_upgradeable::close_any (#21344) (#21353)

(cherry picked from commit 1a7cefded7)

Co-authored-by: Kirill Fomichev <fanatid@ya.ru>
This commit is contained in:
mergify[bot]
2021-11-19 09:10:48 -08:00
committed by GitHub
parent b63617a3e1
commit f3ea9bc995

View File

@ -261,7 +261,7 @@ pub fn close_any(
AccountMeta::new(*recipient_address, false), AccountMeta::new(*recipient_address, false),
]; ];
if let Some(authority_address) = authority_address { if let Some(authority_address) = authority_address {
metas.push(AccountMeta::new(*authority_address, true)); metas.push(AccountMeta::new_readonly(*authority_address, true));
} }
if let Some(program_address) = program_address { if let Some(program_address) = program_address {
metas.push(AccountMeta::new(*program_address, false)); metas.push(AccountMeta::new(*program_address, false));