Chore: remove deprecated ioutil

This commit is contained in:
Dreamacro
2021-10-09 20:35:06 +08:00
parent 1996bef9e6
commit 4ce35870fe
8 changed files with 21 additions and 21 deletions

View File

@ -6,7 +6,6 @@ import (
"errors"
"fmt"
"io"
"io/ioutil"
"net"
"strconv"
@ -116,7 +115,7 @@ func (ss *Socks5) DialUDP(metadata *C.Metadata) (_ C.PacketConn, err error) {
}
go func() {
io.Copy(ioutil.Discard, c)
io.Copy(io.Discard, c)
c.Close()
// A UDP association terminates when the TCP connection that the UDP
// ASSOCIATE request arrived on terminates. RFC1928