Avoid panic on duplicate account indices

This commit is contained in:
Michael Vines
2019-03-19 15:25:46 -07:00
committed by Grimes
parent 061d6ec8fd
commit 8278585545
2 changed files with 19 additions and 14 deletions

View File

@@ -40,6 +40,9 @@ pub enum ProgramError {
/// SystemInstruction::Assign was attempted on an account unowned by the system program
AssignOfUnownedAccount,
/// An account was referenced more than once in a single instruction
DuplicateAccountIndex,
/// CustomError allows on-chain programs to implement program-specific error types and see
/// them returned by the Solana runtime. A CustomError may be any type that is serialized
/// to a Vec of bytes, max length 32 bytes. Any CustomError Vec greater than this length will