Fix strdup() leaks

This commit is contained in:
Alexander 'z33ky' Hirsch
2021-04-25 22:47:55 +02:00
parent a75b0b7d58
commit 036fbda906
4 changed files with 43 additions and 32 deletions

View File

@@ -1240,7 +1240,7 @@ char *CAI_Expresser::ParseApplyContext( const char *szContext )
{
// If it's really 0, then this is a waste of time
Warning("\"%s\" was detected by applyContext operators as an operable number, but it's not.\n", szValue);
return strdup(szContext);
return szContext;
}
// This is the existing value; will be operated upon and become the final assignment