mirror of
https://github.com/SunBK201/UA3F.git
synced 2025-12-16 16:57:08 +00:00
fix: close dup fd
This commit is contained in:
parent
8132085c8c
commit
1558b8a28b
@ -55,6 +55,7 @@ func GetConnFD(conn net.Conn) (fd int, err error) {
|
||||
if err != nil {
|
||||
return 0, fmt.Errorf("tcpConn.File: %v", err)
|
||||
}
|
||||
defer file.Close()
|
||||
|
||||
return int(file.Fd()), nil
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user