Fix gcc build errors & warnings

This commit is contained in:
Alexander 'z33ky' Hirsch
2021-01-27 10:27:03 +01:00
parent 264ee2b04f
commit 49836ab50a
14 changed files with 68 additions and 50 deletions

View File

@@ -199,7 +199,7 @@ void CLogicExternalData::InputWriteKeyValue( inputdata_t &inputdata )
// Separate key from value
char *delimiter = Q_strstr(szValue, " ");
if (delimiter && (delimiter + 1) != '\0')
if (delimiter && delimiter[1] != '\0')
{
Q_strncpy(key, szValue, MIN((delimiter - szValue) + 1, sizeof(key)));
Q_strncpy(value, delimiter + 1, sizeof(value));