Add TODO for upstreamConn.register race
This commit is contained in:
parent
9fb789ee26
commit
a6636a9b0d
2
user.go
2
user.go
@ -205,6 +205,8 @@ func (net *network) runConn(ctx context.Context) error {
|
|||||||
defer net.user.srv.Identd.Delete(uc.RemoteAddr().String(), uc.LocalAddr().String())
|
defer net.user.srv.Identd.Delete(uc.RemoteAddr().String(), uc.LocalAddr().String())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: this is racy, we're not running in the user goroutine yet
|
||||||
|
// uc.register accesses user/network DB records
|
||||||
uc.register(ctx)
|
uc.register(ctx)
|
||||||
if err := uc.runUntilRegistered(ctx); err != nil {
|
if err := uc.runUntilRegistered(ctx); err != nil {
|
||||||
return fmt.Errorf("failed to register: %w", err)
|
return fmt.Errorf("failed to register: %w", err)
|
||||||
|
Loading…
Reference in New Issue
Block a user