Skip to content

Commit ecd79f4

Browse files
authored
Merge pull request #192 from XinFinOrg/feature-v0.3.2
increase tx size limit and better naming
2 parents 25ac457 + c87414d commit ecd79f4

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99

1010
jobs:
1111
test_golang:
12-
name: Test, build and push image to registry
12+
name: Test (unit tests)
1313
runs-on: ubuntu-latest
1414
env:
1515
GOPATH: ${{ github.workspace }}

core/tx_pool.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,8 @@ func (pool *TxPool) validateTx(tx *types.Transaction, local bool) error {
597597
}
598598

599599
// Heuristic limit, reject transactions over 32KB to prevent DOS attacks
600-
if tx.Size() > 32*1024 {
600+
// test size increase TODO: bring over EIP2464 from XDPoS to allow actual 128KB
601+
if tx.Size() > 128*1024 {
601602
return ErrOversizedData
602603
}
603604
// Transactions can't be negative. This may never happen using RLP decoded

eth/hooks/engine_v2_hooks.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ import (
2020
)
2121

2222
func AttachConsensusV2Hooks(adaptor *XDPoS.XDPoS, bc *core.BlockChain, chainConfig *params.ChainConfig) {
23+
2324
// Hook scans for bad masternodes and decide to penalty them
2425
// Subnet penalty is triggered at gap block, and stopped at previous gap block
2526
adaptor.EngineV2.HookPenalty = func(chain consensus.ChainReader, number *big.Int, currentHash common.Hash, candidates []common.Address, config *params.XDPoSConfig) ([]common.Address, error) {

0 commit comments

Comments
 (0)