1
0
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-17 10:52:46 +00:00

Fix clone loading race condition.

This happens on DirtSand shards when two avatars are loading the same age
at once. LoadCloneMsgs are dispatched to the clients before they have
loaded the original keys. The server has no way of knowing that however,
so this is the correct place to fix the problem.
This commit is contained in:
2013-02-06 00:02:06 -05:00
parent 12b2c35561
commit 7020624be4

View File

@ -105,6 +105,12 @@ plKey plNetClientMgr::ILoadClone(plLoadCloneMsg *pCloneMsg)
if(pCloneMsg->GetIsLoading())
{
if (!cloneKey)
{
DebugMsg("ILoadClone: got a null clone key... either a loading race or someone is being naughty.");
return nullptr;
}
if (cloneKey->ObjectIsLoaded())
{
DebugMsg("ILoadClone: object %s is already loaded, ignoring", cloneKey->GetUoid().StringIze().c_str());