From 076a8b8095ad4e1a8f2ad770ce375612dcaf0288 Mon Sep 17 00:00:00 2001 From: Matthew Holt Date: Thu, 8 Sep 2022 13:10:40 -0600 Subject: Very minor tweaks --- listeners.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'listeners.go') diff --git a/listeners.go b/listeners.go index b494910..6a23c61 100644 --- a/listeners.go +++ b/listeners.go @@ -87,6 +87,7 @@ func ListenPacket(network, addr string) (net.PacketConn, error) { // ListenQUIC returns a quic.EarlyListener suitable for use in a Caddy module. // Note that the context passed to Accept is currently ignored, so using // a context other than context.Background is meaningless. +// This API is EXPERIMENTAL and may change. func ListenQUIC(addr string, tlsConf *tls.Config, activeRequests *int64) (quic.EarlyListener, error) { lnKey := listenerKey("udp", addr) @@ -112,8 +113,9 @@ func ListenQUIC(addr string, tlsConf *tls.Config, activeRequests *int64) (quic.E ctx, cancel := context.WithCancel(context.Background()) return &fakeCloseQuicListener{ sharedQuicListener: sharedEl.(*sharedQuicListener), - context: ctx, contextCancel: cancel, - }, err + context: ctx, + contextCancel: cancel, + }, nil } // ListenerUsage returns the current usage count of the given listener address. -- cgit v1.2.3