Skip to content

Commit 4bcded5

Browse files
authored
Crash fix (#4206)
1 parent e36e109 commit 4bcded5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Client/multiplayer_sa/CMultiplayerSA.cpp

+6-1
Original file line numberDiff line numberDiff line change
@@ -6443,7 +6443,12 @@ void _declspec(naked) HOOK_CWorld_Remove_CPopulation_ConvertToDummyObject()
64436443
TIMING_CHECKPOINT("+RemovePointerToBuilding");
64446444
RemovePointerToBuilding();
64456445
StorePointerToBuilding();
6446-
RemoveObjectIfNeeded();
6446+
6447+
// pLODInterface contains a dummy object's pointer
6448+
// And as follows from CPopulation::ConvertToDummyObject this pointer can be nullptr
6449+
if (pLODInterface)
6450+
RemoveObjectIfNeeded();
6451+
64476452
TIMING_CHECKPOINT("-RemovePointerToBuilding");
64486453
_asm
64496454
{

0 commit comments

Comments
 (0)