summaryrefslogtreecommitdiff
path: root/src/modelinfo/TimeModelInfo.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-12-25 15:18:48 +0200
committerSergeanur <s.anureev@yandex.ua>2020-12-25 15:18:48 +0200
commite00b8a93bf7a53ef09bc349aefd3a2a37d58f09e (patch)
tree924da3fee9f1013e15de1ffa6a7f72e9537e46e1 /src/modelinfo/TimeModelInfo.cpp
parentdc72729a40b7710ce734cdd76c34b7c91c5f714a (diff)
Fix use of strncmp
Diffstat (limited to 'src/modelinfo/TimeModelInfo.cpp')
-rw-r--r--src/modelinfo/TimeModelInfo.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/modelinfo/TimeModelInfo.cpp b/src/modelinfo/TimeModelInfo.cpp
index d4f92293..c1c18dac 100644
--- a/src/modelinfo/TimeModelInfo.cpp
+++ b/src/modelinfo/TimeModelInfo.cpp
@@ -2,6 +2,7 @@
#include "Camera.h"
#include "ModelInfo.h"
+#include "General.h"
CTimeModelInfo*
CTimeModelInfo::FindOtherTimeModel(void)
@@ -23,7 +24,7 @@ CTimeModelInfo::FindOtherTimeModel(void)
for(i = 0; i < MODELINFOSIZE; i++){
CBaseModelInfo *mi = CModelInfo::GetModelInfo(i);
if (mi && mi->GetModelType() == MITYPE_TIME &&
- strncmp(name, mi->GetName(), 24) == 0){
+ !CGeneral::faststrncmp(name, mi->GetName(), MAX_MODEL_NAME)){
m_otherTimeModelID = i;
return (CTimeModelInfo*)mi;
}