diff options
author | Zack Middleton <zturtleman@gmail.com> | 2015-07-12 21:14:04 -0500 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2016-04-07 11:02:31 +0100 |
commit | 217f61a252c1e9d7da6fbfb8a30c421b4a264a8a (patch) | |
tree | 35e7d6eb2555ff5a6335680f58048b1878e9e5d9 | |
parent | a52594f2d8b955c7bd0aab990f5033a7a2d87afa (diff) |
Remove logically dead code from CL_GetServerStatus
Found by Coverity.
-rw-r--r-- | src/client/cl_main.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/client/cl_main.c b/src/client/cl_main.c index 77df2e01..0199a520 100644 --- a/src/client/cl_main.c +++ b/src/client/cl_main.c @@ -149,7 +149,6 @@ typedef struct serverStatus_s } serverStatus_t; serverStatus_t cl_serverStatusList[MAX_SERVERSTATUSREQUESTS]; -int serverStatusCount; #if defined __USEA3D && defined __A3D_GEOM void hA3Dg_ExportRenderGeom (refexport_t *incoming_re); @@ -4005,11 +4004,7 @@ serverStatus_t *CL_GetServerStatus( netadr_t from ) { oldestTime = cl_serverStatusList[i].startTime; } } - if (oldest != -1) { - return &cl_serverStatusList[oldest]; - } - serverStatusCount++; - return &cl_serverStatusList[serverStatusCount & (MAX_SERVERSTATUSREQUESTS-1)]; + return &cl_serverStatusList[oldest]; } /* |