diff --git a/src/swrenderer/line/r_walldraw.cpp b/src/swrenderer/line/r_walldraw.cpp
index 00d5d4860f..bf8d856e9d 100644
--- a/src/swrenderer/line/r_walldraw.cpp
+++ b/src/swrenderer/line/r_walldraw.cpp
@@ -99,7 +99,7 @@ namespace swrenderer
 			v = v - floor(v);
 			double v_step = uv_stepd / texture->GetHeight();
 
-			if (std::isnan(v) || std::isnan(v_step)) // this should never happen, but it apparently does..
+			if (isnan(v) || isnan(v_step)) // this should never happen, but it apparently does..
 			{
 				uv_stepd = 0.0;
 				v = 0.0;