diff --git a/config/protocol.mainnet.yml b/config/protocol.mainnet.yml index ad32fd516..8088ae6bb 100644 --- a/config/protocol.mainnet.yml +++ b/config/protocol.mainnet.yml @@ -19,7 +19,6 @@ ProtocolConfiguration: - seed5.neo.org:10333 VerifyBlocks: true VerifyTransactions: false - FreeGasLimit: 10.0 MaxTransactionsPerBlock: 500 MaxFreeTransactionsPerBlock: 20 MaxFreeTransactionSize: 1024 diff --git a/config/protocol.testnet.yml b/config/protocol.testnet.yml index d306b9386..41ca65e51 100644 --- a/config/protocol.testnet.yml +++ b/config/protocol.testnet.yml @@ -19,7 +19,6 @@ ProtocolConfiguration: - seed5t.neo.org:20333 VerifyBlocks: true VerifyTransactions: false - FreeGasLimit: 10.0 MaxTransactionsPerBlock: 500 MaxFreeTransactionsPerBlock: 20 MaxFreeTransactionSize: 1024 diff --git a/pkg/config/protocol_config.go b/pkg/config/protocol_config.go index 151accf24..96cba7502 100644 --- a/pkg/config/protocol_config.go +++ b/pkg/config/protocol_config.go @@ -2,7 +2,6 @@ package config import ( "github.com/nspcc-dev/neo-go/pkg/config/netmode" - "github.com/nspcc-dev/neo-go/pkg/util" ) // ProtocolConfiguration represents the protocol config. @@ -10,9 +9,7 @@ type ( ProtocolConfiguration struct { // FeePerExtraByte sets the expected per-byte fee for // transactions exceeding the MaxFreeTransactionSize. - FeePerExtraByte float64 `yaml:"FeePerExtraByte"` - // FreeGasLimit is an amount of GAS which can be spent for free. - FreeGasLimit util.Fixed8 `yaml:"FreeGasLimit"` + FeePerExtraByte float64 `yaml:"FeePerExtraByte"` LowPriorityThreshold float64 `yaml:"LowPriorityThreshold"` Magic netmode.Magic `yaml:"Magic"` MaxTransactionsPerBlock int `yaml:"MaxTransactionsPerBlock"` diff --git a/pkg/core/blockchain.go b/pkg/core/blockchain.go index 2bb20863d..cfec49171 100644 --- a/pkg/core/blockchain.go +++ b/pkg/core/blockchain.go @@ -605,9 +605,7 @@ func (bc *Blockchain) storeBlock(block *block.Block) error { v := SpawnVM(systemInterop) v.LoadScriptWithFlags(tx.Script, smartcontract.All) v.SetPriceGetter(getPrice) - if bc.config.FreeGasLimit > 0 { - v.GasLimit = bc.config.FreeGasLimit + tx.SystemFee - } + v.GasLimit = tx.SystemFee err := v.Run() if !v.HasFailed() {