From 983e8bc6a5714f0d317d2458f8346c6d6c01a98c Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Sat, 5 Mar 2016 22:39:53 +0100 Subject: [PATCH] - explicitly check NAME_Null in P_FindTerrain so that it cannot get rendered inoperable by mods which hijack this name. This name must be reserved so that there is some means to disable a sector's terrain. --- src/p_terrain.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/p_terrain.cpp b/src/p_terrain.cpp index 37c2bda0e..3c6519393 100644 --- a/src/p_terrain.cpp +++ b/src/p_terrain.cpp @@ -702,6 +702,7 @@ int P_FindTerrain (FName name) { unsigned int i; + if (name == NAME_Null) return -1; for (i = 0; i < Terrains.Size (); i++) { if (Terrains[i].Name == name)