From: havoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Date: Sun, 23 Oct 2005 20:24:03 +0000 (+0000)
Subject: fixed a bug that was making "Model %s not found" warnings never appear when parsing... 
X-Git-Tag: xonotic-v0.1.0preview~4525
X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=5f18c4eea23e0d12cc50afd33e95fb5f50e1d9d0;p=xonotic%2Fdarkplaces.git

fixed a bug that was making "Model %s not found" warnings never appear when parsing the model precache list


git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5759 d7cf8633-e32d-0410-b094-e92efae38249
---

diff --git a/cl_parse.c b/cl_parse.c
index 5933c863..2ecbd6d7 100644
--- a/cl_parse.c
+++ b/cl_parse.c
@@ -448,14 +448,14 @@ void CL_ParseServerInfo (void)
 	// world model
 	CL_KeepaliveMessage ();
 	cl.model_precache[1] = Mod_ForName(parse_model_precache[1], false, false, true);
-	if (cl.model_precache[1] == NULL)
+	if (cl.model_precache[1]->Draw == NULL)
 		Con_Printf("Map %s not found\n", parse_model_precache[1]);
 
 	// normal models
 	for (i=2 ; i<nummodels ; i++)
 	{
 		CL_KeepaliveMessage();
-		if ((cl.model_precache[i] = Mod_ForName(parse_model_precache[i], false, false, false)) == NULL)
+		if ((cl.model_precache[i] = Mod_ForName(parse_model_precache[i], false, false, false))->Draw == NULL)
 			Con_Printf("Model %s not found\n", parse_model_precache[i]);
 	}