File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -6600,13 +6600,16 @@ int EXT_FUNC RegUserMsg(const char *pszName, int iSize)
66006600 if (!pszName || Q_strlen (pszName) >= MAX_USERMESSAGES_LENGTH - 1 )
66016601 return 0 ;
66026602
6603- UserMsg *pUserMsgs = sv_gpUserMsgs;
6604- while (pUserMsgs)
6603+ for (UserMsg *pMsg = sv_gpUserMsgs; pMsg; pMsg = pMsg->next )
66056604 {
6606- if (!Q_strcmp (pszName, pUserMsgs->szName ))
6607- return pUserMsgs->iMsg ;
6605+ if (!Q_strcmp (pszName, pMsg->szName ))
6606+ return pMsg->iMsg ;
6607+ }
66086608
6609- pUserMsgs = pUserMsgs->next ;
6609+ for (UserMsg *pMsg = sv_gpNewUserMsgs; pMsg; pMsg = pMsg->next )
6610+ {
6611+ if (!Q_strcmp (pszName, pMsg->szName ))
6612+ return pMsg->iMsg ;
66106613 }
66116614
66126615 UserMsg *pNewMsg = (UserMsg *)Mem_ZeroMalloc (sizeof (UserMsg));
You can’t perform that action at this time.
0 commit comments