mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 02:42:49 -04:00
protect for threading
This commit is contained in:
parent
1fc71a28e8
commit
39a745bdaa
@ -302,8 +302,7 @@ class ServerRepository:
|
|||||||
return task.cont
|
return task.cont
|
||||||
|
|
||||||
# Crazy dereferencing
|
# Crazy dereferencing
|
||||||
newConnection=newConnection.p()
|
newConnection = newConnection.p()
|
||||||
self.qcr.addConnection(newConnection)
|
|
||||||
|
|
||||||
# Add clients information to dictionary
|
# Add clients information to dictionary
|
||||||
id = self.idAllocator.allocate()
|
id = self.idAllocator.allocate()
|
||||||
@ -316,6 +315,9 @@ class ServerRepository:
|
|||||||
self.clientsByConnection[client.connection] = client
|
self.clientsByConnection[client.connection] = client
|
||||||
self.clientsByDoIdBase[client.doIdBase] = client
|
self.clientsByDoIdBase[client.doIdBase] = client
|
||||||
|
|
||||||
|
# Now we can start listening to that new connection.
|
||||||
|
self.qcr.addConnection(newConnection)
|
||||||
|
|
||||||
self.lastConnection = newConnection
|
self.lastConnection = newConnection
|
||||||
self.sendDoIdRange(client)
|
self.sendDoIdRange(client)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user