File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -455,7 +455,7 @@ where
455455 sender_state. sequence += 1 ;
456456
457457 // Ensure from actor has enough balance to cover the gas cost of the message.
458- let gas_cost: TokenAmount = msg. gas_fee_cap . clone ( ) * msg. gas_limit ;
458+ let gas_cost: TokenAmount = & msg. gas_fee_cap * msg. gas_limit ;
459459 if sender_state. balance < gas_cost {
460460 return Ok ( Err ( ApplyRet :: prevalidation_fail (
461461 ExitCode :: SYS_SENDER_STATE_INVALID ,
Original file line number Diff line number Diff line change @@ -1003,7 +1003,7 @@ where
10031003 . iter ( )
10041004 . collect ( ) ;
10051005
1006- if let Err ( e) = std:: fs:: create_dir_all ( dir. clone ( ) ) {
1006+ if let Err ( e) = std:: fs:: create_dir_all ( & dir) {
10071007 log:: error!( "failed to make directory to store debug artifacts {}" , e) ;
10081008 } else if let Err ( e) = std:: fs:: write ( dir. join ( name) , data) {
10091009 log:: error!( "failed to store debug artifact {}" , e)
Original file line number Diff line number Diff line change @@ -205,7 +205,7 @@ pub fn compute_unsealed_sector_cid(
205205 proof_type : RegisteredSealProof ,
206206 pieces : & [ PieceInfo ] ,
207207) -> SyscallResult < Cid > {
208- let pieces = to_vec ( & pieces. to_vec ( ) ) . expect ( "failed to marshal piece infos" ) ;
208+ let pieces = to_vec ( pieces) . expect ( "failed to marshal piece infos" ) ;
209209 let pieces = pieces. as_slice ( ) ;
210210 let mut out = [ 0u8 ; MAX_CID_LEN ] ;
211211 unsafe {
Original file line number Diff line number Diff line change @@ -64,7 +64,7 @@ fn build_response(send: fvm_shared::sys::out::send::Send) -> SyscallResult<fvm_s
6464
6565 Some ( fvm_ipld_encoding:: ipld_block:: IpldBlock {
6666 codec : send. return_codec ,
67- data : bytes. to_vec ( ) ,
67+ data : bytes,
6868 } )
6969 } ;
7070
You can’t perform that action at this time.
0 commit comments