Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

net: unix autobind listen panics #6455

Closed
alberts opened this issue Sep 23, 2013 · 2 comments

Comments

Projects
None yet
4 participants
@alberts
Copy link
Contributor

commented Sep 23, 2013

What steps will reproduce the problem?

TestUnixAutobindClose in the following CL panics:

https://golang.org/cl/13457058/

panic: runtime error: index out of range

goroutine 4 [running]:
runtime.panic(0x5dd8c0, 0xc210070390)
    /home/alberts/go.tip/src/pkg/runtime/panic.c:266 +0xb6
testing.func·005()
    /home/alberts/go.tip/src/pkg/testing/testing.go:383 +0xe8
runtime.panic(0x5dd8c0, 0xc210070390)
    /home/alberts/go.tip/src/pkg/runtime/panic.c:248 +0x106
net.(*UnixListener).Close(0xc21006cf40, 0x4, 0xc21006cf00)
    /home/alberts/go.tip/src/pkg/net/unixsock_posix.go:319 +0x98
net.TestUnixAutobindClose(0xc21006d090)
    /home/alberts/go.tip/src/pkg/net/unix_test.go:151 +0x150
testing.tRunner(0xc21006d090, 0x828e08)
    /home/alberts/go.tip/src/pkg/testing/testing.go:389 +0x8b
created by testing.RunTests
    /home/alberts/go.tip/src/pkg/testing/testing.go:469 +0x8b2

this is because laddr.Name is an empty string, but the code checks for Name[0] being
equal to '@'.

What do you see instead?

panic

Which compiler are you using (5g, 6g, 8g, gccgo)?

6g

Which operating system are you using?

linux

Which version are you using?  (run 'go version')

tip

Please provide any additional information below.

https://golang.org/cl/13457058/
@ianlancetaylor

This comment has been minimized.

Copy link
Contributor

commented Sep 23, 2013

Comment 1:

Labels changed: added priority-soon, go1.2maybe, removed priority-triage.

@rsc

This comment has been minimized.

Copy link
Contributor

commented Sep 24, 2013

Comment 2:

This issue was closed by revision 2be6236.

Status changed to Fixed.

@alberts alberts added fixed labels Sep 24, 2013

@rsc rsc added this to the Go1.2 milestone Apr 14, 2015

@rsc rsc removed the go1.2maybe label Apr 14, 2015

@golang golang locked and limited conversation to collaborators Jun 25, 2016

This issue was closed.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.