Skip to content

Deadlock udp/forwarder.go:CreateEndpoint calling into udp/endpoint.go:Close #98

Closed

Description

@ignoramous

Re-entring a critical section with a non re-entrant ep.mu mutex already held.

goroutine 5215 [sync.Mutex.Lock, 11 minutes]:
sync.runtime_SemacquireMutex(0x400912d5e8?, 0x9c?, 0x0?)
	/home/jitpack/golang/go/src/runtime/sema.go:95 +0x28
sync.(*Mutex).lockSlow(0x4008f07468)
	/home/jitpack/golang/go/src/sync/mutex.go:173 +0x174
sync.(*Mutex).Lock(...)
	/home/jitpack/golang/go/src/sync/mutex.go:92
gvisor.dev/gvisor/pkg/sync.(*CrossGoroutineMutex).Lock(...)
	/tmp/gomobile-work-3018107916/pkg/mod/gvisor.dev/gvisor@v0.0.0-20240729225701-924c9908865c/pkg/sync/mutex_unsafe.go:22
gvisor.dev/gvisor/pkg/sync.(*CrossGoroutineRWMutex).Lock(0x4008f07468)
	/tmp/gomobile-work-3018107916/pkg/mod/gvisor.dev/gvisor@v0.0.0-20240729225701-924c9908865c/pkg/sync/rwmutex_unsafe.go:147 +0x74
gvisor.dev/gvisor/pkg/sync.(*RWMutex).Lock(...)
	/tmp/gomobile-work-3018107916/pkg/mod/gvisor.dev/gvisor@v0.0.0-20240729225701-924c9908865c/pkg/sync/rwmutex_unsafe.go:290
gvisor.dev/gvisor/pkg/tcpip/transport/udp.(*endpoint).Close(0x4008f07188)
	/tmp/gomobile-work-3018107916/pkg/mod/gvisor.dev/gvisor@v0.0.0-20240729225701-924c9908865c/pkg/tcpip/transport/udp/endpoint.go:162 +0x40
gvisor.dev/gvisor/pkg/tcpip/transport/udp.(*ForwarderRequest).CreateEndpoint(0x40088703c0, 0x4008a5b888?)
	/tmp/gomobile-work-3018107916/pkg/mod/gvisor.dev/gvisor@v0.0.0-20240729225701-924c9908865c/pkg/tcpip/transport/udp/forwarder.go:87 +0x444
github.com/celzero/firestack/intra/netstack.(*GUDPConn).Establish(0x4008fbc420)
	/home/jitpack/build/intra/netstack/udp.go:204 +0x60
github.com/celzero/firestack/intra.(*udpHandler).Connect(0x400013a600, 0x4008fbc420, {{{0x0, 0xffff0a6fde01}, {0x400013e450}}, 0xd7a6}, {{{0x0, 0xffff646f4883}, {0x400013e450}}, 0x1bb}, ...)
	/home/jitpack/build/intra/udp.go:238 +0x7c
github.com/celzero/firestack/intra.(*udpHandler).proxy(0x400013a600, 0x4008fbc420, {{{0x0, 0xffff0a6fde01}, {0x400013e450}}, 0xd7a6}, {{{0x0, 0xffff646f4883}, {0x400013e450}}, 0x1bb}, ...)
	/home/jitpack/build/intra/udp.go:203 +0x50
github.com/celzero/firestack/intra.(*udpHandler).Proxy(0xcfe6?, 0x4008aecc40?, {{{0x7de4795480?, 0x4008aecc40?}, {0x400013e450?}}, 0xa08?}, {{{0x0?, 0x7de4400a04?}, {0x400013e450?}}, 0xbf88?})
	/home/jitpack/build/intra/udp.go:197 +0x48
created by github.com/celzero/firestack/intra/netstack.Up.OutboundUDP.udpForwarder.func1 in goroutine 295
	/home/jitpack/build/intra/netstack/udp.go:168 +0x3a8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions