fix a udp bug
fix udp bug error: use of closed network connection
This commit is contained in:
@@ -229,6 +229,7 @@ func (c *conn) SetIdle(idle bool) {
|
||||
func (c *conn) WriteQueue(b []byte) error {
|
||||
select {
|
||||
case c.rc <- b:
|
||||
c.SetIdle(false)
|
||||
return nil
|
||||
|
||||
case <-c.closed:
|
||||
|
||||
Reference in New Issue
Block a user