1
0
mirror of https://github.com/golang/go synced 2024-11-23 22:40:04 -07:00

net: remove unixgram test sockets

Updates https://gcc.gnu.org/PR89406

Change-Id: Iccf2760e42e9caa90720b96e74a805a9c0d48f35
Reviewed-on: https://go-review.googlesource.com/c/163277
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Mikio Hara <mikioh.public.networking@gmail.com>
Reviewed-by: Than McIntosh <thanm@google.com>
This commit is contained in:
Ian Lance Taylor 2019-02-20 16:34:48 -08:00
parent 4b05dc91b0
commit b97e40fc30
3 changed files with 4 additions and 2 deletions

View File

@ -780,6 +780,9 @@ func TestListenConfigControl(t *testing.T) {
continue
}
c.Close()
if network == "unixgram" {
os.Remove(address)
}
}
})
}

View File

@ -17,8 +17,6 @@ import (
)
// testUnixAddr uses ioutil.TempFile to get a name that is unique.
// It also uses /tmp directory in case it is prohibited to create UNIX
// sockets in TMPDIR.
func testUnixAddr() string {
f, err := ioutil.TempFile("", "go-nettest")
if err != nil {

View File

@ -242,6 +242,7 @@ func testSpliceNoUnixgram(t *testing.T) {
if err != nil {
t.Fatal(err)
}
defer os.Remove(addr.Name)
up, err := ListenUnixgram("unixgram", addr)
if err != nil {
t.Fatal(err)