parent
28a6424f38
commit
f4f2e781ff
|
@ -1,11 +1,7 @@
|
|||
use byteorder::{ByteOrder, LittleEndian, WriteBytesExt};
|
||||
use solana_sdk::{
|
||||
account::{ReadableAccount, WritableAccount},
|
||||
bpf_loader_deprecated,
|
||||
entrypoint::MAX_PERMITTED_DATA_INCREASE,
|
||||
instruction::InstructionError,
|
||||
keyed_account::KeyedAccount,
|
||||
pubkey::Pubkey,
|
||||
account::ReadableAccount, bpf_loader_deprecated, entrypoint::MAX_PERMITTED_DATA_INCREASE,
|
||||
instruction::InstructionError, keyed_account::KeyedAccount, pubkey::Pubkey,
|
||||
};
|
||||
use std::{
|
||||
io::prelude::*,
|
||||
|
@ -258,7 +254,7 @@ pub fn deserialize_parameters_aligned(
|
|||
start += size_of::<Pubkey>(); // owner
|
||||
account.lamports = LittleEndian::read_u64(&buffer[start..]);
|
||||
start += size_of::<u64>(); // lamports
|
||||
let pre_len = account.data_as_mut_slice().len();
|
||||
let pre_len = account.data().len();
|
||||
let post_len = LittleEndian::read_u64(&buffer[start..]) as usize;
|
||||
start += size_of::<u64>(); // data length
|
||||
let mut data_end = start + pre_len;
|
||||
|
|
Loading…
Reference in New Issue