Add quic-v1 protocol ID to listen_on

This commit is contained in:
Luke Parker 2023-11-25 23:03:31 -05:00
parent 8d54419ddc
commit 964284e774
No known key found for this signature in database

View file

@ -279,7 +279,7 @@ impl LibP2p {
.unwrap()
.build();
const PORT: u16 = 30563; // 5132 ^ (('c' << 8) | 'o')
swarm.listen_on(format!("/ip4/0.0.0.0/udp/{PORT}").parse().unwrap()).unwrap();
swarm.listen_on(format!("/ip4/0.0.0.0/udp/{PORT}/quic-v1").parse().unwrap()).unwrap();
let (broadcast_send, mut broadcast_recv) = mpsc::unbounded_channel();
let (receive_send, receive_recv) = mpsc::unbounded_channel();