Skip to content

Commit 6f7e049

Browse files
authored
Merge pull request #909 from lochjin/dev2.0
fix:Unable to transmit evm-tx in non-SnapSync mode
2 parents 3232d97 + 619a3b6 commit 6f7e049

File tree

3 files changed

+2
-6
lines changed

3 files changed

+2
-6
lines changed

p2p/synch/meerevm.go

-3
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,6 @@ func (ps *PeerSync) checkMeerConnection(pe *peers.Peer) bool {
3232
if !pe.IsSupportMeerP2PBridging() {
3333
return false
3434
}
35-
if !pe.IsSnap() {
36-
return false
37-
}
3835
if pe.Direction() != network.DirOutbound {
3936
return false
4037
}

p2p/synch/mempool.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ func (ps *PeerSync) OnMemPool(sp *peers.Peer, msg *MsgMemPool) error {
6060
// per message. The NewMsgInvSizeHint function automatically limits
6161
// the passed hint to the maximum allowed, so it's safe to pass it
6262
// without double checking it here.
63-
txDescs := ps.sy.p2p.TxMemPool().TxDescs(ps.sy.p2p.Consensus().Config().TranferTxLegacyMode && !sp.IsSupportMeerpoolTransmission())
63+
txDescs := ps.sy.p2p.TxMemPool().TxDescs(!sp.IsSupportMeerpoolTransmission())
6464

6565
invs := []*pb.InvVect{}
6666
for _, txDesc := range txDescs {

p2p/synch/peersync.go

+1-2
Original file line numberDiff line numberDiff line change
@@ -491,8 +491,7 @@ func (ps *PeerSync) RelayInventory(nds []*notify.NotifyData) {
491491
switch value := nd.Data.(type) {
492492
case *types.TxDesc:
493493
if types.IsCrossChainVMTx(value.Tx.Tx) {
494-
if !ps.sy.p2p.Consensus().Config().TranferTxLegacyMode ||
495-
pe.IsSupportMeerpoolTransmission() {
494+
if pe.IsSupportMeerpoolTransmission() {
496495
continue
497496
}
498497
}

0 commit comments

Comments
 (0)