config/packages/networking/hyprspace/0002-Remove-quic-transport-for-Lain-ipfs.patch

49 lines
1.5 KiB
Diff
Raw Normal View History

2022-02-05 21:42:36 +02:00
From 743c2cc62daa48bbdcce038ad21805b906e8ddaf Mon Sep 17 00:00:00 2001
From: Tiago Carvalho <sugoiuguu@tfwno.gf>
Date: Sat, 5 Feb 2022 15:16:33 +0000
Subject: [PATCH 2/3] Remove quic transport for Lain ipfs
---
p2p/node.go | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/p2p/node.go b/p2p/node.go
index 736101a..2f86317 100644
--- a/p2p/node.go
+++ b/p2p/node.go
@@ -15,7 +15,6 @@ import (
"github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/pnet"
dht "github.com/libp2p/go-libp2p-kad-dht"
- libp2pquic "github.com/libp2p/go-libp2p-quic-transport"
"github.com/libp2p/go-tcp-transport"
ma "github.com/multiformats/go-multiaddr"
)
@@ -36,9 +35,6 @@ func CreateNode(ctx context.Context, inputKey string, port int, handler network.
return
}
- ip6quic := fmt.Sprintf("/ip6/::/udp/%d/quic", port)
- ip4quic := fmt.Sprintf("/ip4/0.0.0.0/udp/%d/quic", port)
-
ip6tcp := fmt.Sprintf("/ip6/::/tcp/%d", port)
ip4tcp := fmt.Sprintf("/ip4/0.0.0.0/tcp/%d", port)
@@ -47,12 +43,11 @@ func CreateNode(ctx context.Context, inputKey string, port int, handler network.
// Create libp2p node
node, err = libp2p.New(
libp2p.PrivateNetwork(key),
- libp2p.ListenAddrStrings(ip6quic, ip4quic, ip6tcp, ip4tcp),
+ libp2p.ListenAddrStrings(ip6tcp, ip4tcp),
libp2p.Identity(privateKey),
libp2p.DefaultSecurity,
libp2p.NATPortMap(),
libp2p.DefaultMuxers,
- libp2p.Transport(libp2pquic.NewTransport),
libp2p.Transport(tcp.NewTCPTransport),
libp2p.FallbackDefaults,
)
--
2.34.1