summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Mobs/Path.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Mobs/Path.cpp b/src/Mobs/Path.cpp
index 32eff9d2b..d1b9d6963 100644
--- a/src/Mobs/Path.cpp
+++ b/src/Mobs/Path.cpp
@@ -117,7 +117,7 @@ bool cPath::IsSolid(const Vector3d & a_Location)
{
ASSERT(m_Chunk != nullptr);
m_Chunk = m_Chunk->GetNeighborChunk(a_Location.x, a_Location.z);
- if (!m_Chunk->IsValid())
+ if ((m_Chunk == nullptr) || (!m_Chunk->IsValid()))
{
return true;
}