|
@@ -29,7 +29,7 @@ use log::{debug, error, warn};
|
|
|
use crate::{
|
|
use crate::{
|
|
|
blockchain::{BlockInfo, BlockchainOverlayPtr},
|
|
blockchain::{BlockInfo, BlockchainOverlayPtr},
|
|
|
error::TxVerifyFailed,
|
|
error::TxVerifyFailed,
|
|
|
- runtime::vm_runtime::{Runtime, GAS_LIMIT},
|
|
|
|
|
|
|
+ runtime::vm_runtime::Runtime,
|
|
|
tx::Transaction,
|
|
tx::Transaction,
|
|
|
util::time::TimeKeeper,
|
|
util::time::TimeKeeper,
|
|
|
validator::{
|
|
validator::{
|
|
@@ -204,12 +204,11 @@ pub async fn verify_producer_transaction(
|
|
|
let tx_hash = tx.hash()?;
|
|
let tx_hash = tx.hash()?;
|
|
|
debug!(target: "validator::verification::verify_producer_transaction", "Validating proposal transaction {}", tx_hash);
|
|
debug!(target: "validator::verification::verify_producer_transaction", "Validating proposal transaction {}", tx_hash);
|
|
|
|
|
|
|
|
- // Producer transactions must contain a single, non-empty call
|
|
|
|
|
|
|
+ // Producer transactions must contain a single, non-empty call
|
|
|
if tx.calls.len() != 1 || tx.calls[0].data.is_empty() {
|
|
if tx.calls.len() != 1 || tx.calls[0].data.is_empty() {
|
|
|
return Err(TxVerifyFailed::ErroneousTxs(vec![tx.clone()]).into())
|
|
return Err(TxVerifyFailed::ErroneousTxs(vec![tx.clone()]).into())
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
-
|
|
|
|
|
// Verify call based on version
|
|
// Verify call based on version
|
|
|
let call = &tx.calls[0];
|
|
let call = &tx.calls[0];
|
|
|
match block_version {
|
|
match block_version {
|