mirror of
https://github.com/shtorm-7/sing-box-extended.git
synced 2026-12-04 15:48:38 +00:00
Fix endpoint lifecycle ordering and device reconfiguration
This commit is contained in:
@@ -478,10 +478,10 @@ func (e *Endpoint) readLoop(ctx context.Context) {
|
||||
err = e.device.WriteInboundBuffers(packetBuffers)
|
||||
buf.ReleaseMulti(packetBuffers)
|
||||
if err != nil {
|
||||
err = E.Cause(err, "write packet to device")
|
||||
e.logger.Error(err)
|
||||
e.setTerminalError(err)
|
||||
return
|
||||
if E.IsCanceled(err) || ctx.Err() != nil {
|
||||
return
|
||||
}
|
||||
e.logger.Debug(E.Cause(err, "write packet to device"))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user