Skip to content

Commit

Permalink
use keepalive in quic by default
Browse files Browse the repository at this point in the history
  • Loading branch information
asim committed Aug 11, 2019
1 parent e613b0c commit 56df10f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions transport/quic/quic.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ func (q *quicTransport) Dial(addr string, opts ...transport.DialOption) (transpo
NextProtos: []string{"http/1.1"},
}
}
s, err := quic.DialAddr(addr, config, nil)
s, err := quic.DialAddr(addr, config, &quic.Config{KeepAlive: true})
if err != nil {
return nil, err
}
Expand Down Expand Up @@ -156,7 +156,7 @@ func (q *quicTransport) Listen(addr string, opts ...transport.ListenOption) (tra
}
}

l, err := quic.ListenAddr(addr, config, nil)
l, err := quic.ListenAddr(addr, config, &quic.Config{KeepAlive: true})
if err != nil {
return nil, err
}
Expand Down

0 comments on commit 56df10f

Please sign in to comment.