Various misc. tweaks and fixes based on static code analysis to minimize/fix memleaks, crashes, or other performance impacting code.

This commit is contained in:
Areloch 2020-09-19 18:25:10 -05:00
parent d76c73c252
commit 8956559bfd
44 changed files with 124 additions and 258 deletions

View file

@ -339,8 +339,13 @@ bool WheeledVehicleData::preload(bool server, String &errorStr)
// Resolve objects transmitted from server
if (!server) {
for (S32 i = 0; i < MaxSounds; i++)
if( !sfxResolve( &sound[ i ], errorStr ) )
{
if (!sfxResolve(&sound[i], errorStr))
{
delete si;
return false;
}
}
if (tireEmitter)
Sim::findObject(SimObjectId((uintptr_t)tireEmitter),tireEmitter);