fix(udp): завершать релей при отказе чтения локального сокета

This commit is contained in:
samosvalishe committed 2026-09-22 20:03:54 +03:00
1 parent 192dd27a1e
commit f4e8e0cfe0
3 files changed
+30 -5

No files matched your search

+3 -1
View File
@@ -125,7 +125,9 @@ func Run(ctx context.Context, dtlsDialer *dtlsdial.Dialer, auth AuthHandler, log
inboundChan := make(chan *Packet, inboundQueueCap)
wg := sync.WaitGroup{}
wg.Go(deps.guard(func() {
runListener(runCtx, listenConn, &activeLocalPeer, inboundChan)
if err := runListener(runCtx, listenConn, &activeLocalPeer, inboundChan); err != nil && runCtx.Err() == nil {
deps.fatal(err)
}
}))
// Стрим 1 стартует первым для прогрева кэша учетных данных.