mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 18:59:09 +00:00
Fix a bunch of warnings from clang.
This commit is contained in:
@ -446,7 +446,7 @@ public:
|
||||
plSimpleStateVariable* FindVar(const char* name) const { return (plSimpleStateVariable*)IFindVar(fVarsList, name); }
|
||||
plSDStateVariable* FindSDVar(const char* name) const { return (plSDStateVariable*)IFindVar(fSDVarsList, name); }
|
||||
|
||||
plStateDataRecord& operator=(const plStateDataRecord& other) { CopyFrom(other); }
|
||||
plStateDataRecord& operator=(const plStateDataRecord& other) { CopyFrom(other); return *this; }
|
||||
void CopyFrom(const plStateDataRecord& other, UInt32 writeOptions=0);
|
||||
void UpdateFrom(const plStateDataRecord& other, UInt32 writeOptions=0);
|
||||
void SetFromDefaults(bool timeStampNow);
|
||||
|
@ -92,12 +92,12 @@ public:
|
||||
int fDataLen;
|
||||
|
||||
plSDLCreatableStub(UInt16 classIndex, int len) : fClassIndex(classIndex),fData(nil),fDataLen(len) {}
|
||||
~plSDLCreatableStub() { delete [] fData; }
|
||||
~plSDLCreatableStub() { delete[] (char*)fData; }
|
||||
|
||||
const char* ClassName() const { return "SDLCreatable"; }
|
||||
UInt16 ClassIndex() const { return fClassIndex; }
|
||||
|
||||
void Read(hsStream* s, hsResMgr* mgr) { delete [] fData; fData = TRACKED_NEW char[fDataLen]; s->Read(fDataLen, fData); }
|
||||
void Read(hsStream* s, hsResMgr* mgr) { delete[] (char*)fData; fData = new char[fDataLen]; s->Read(fDataLen, fData); }
|
||||
void Write(hsStream* s, hsResMgr* mgr) { s->Write(fDataLen, fData); }
|
||||
};
|
||||
|
||||
@ -112,7 +112,7 @@ void plStateVarNotificationInfo::Read(hsStream* s, UInt32 readOptions)
|
||||
if (hint && !(readOptions & plSDL::kSkipNotificationInfo))
|
||||
fHintString = (const char*)hint;
|
||||
// we're done with it...
|
||||
delete [] hint;
|
||||
delete[] hint;
|
||||
}
|
||||
|
||||
void plStateVarNotificationInfo::Write(hsStream* s, UInt32 writeOptions) const
|
||||
@ -1874,6 +1874,8 @@ bool plSimpleStateVariable::IWriteData(hsStream* s, float timeConvert, int idx,
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@ -2162,6 +2164,7 @@ void plSimpleStateVariable::NotifyStateChange(const plSimpleStateVariable* other
|
||||
NOTIFY_CHECK(plVarDescriptor::kByte, fBy)
|
||||
NOTIFY_CHECK(plVarDescriptor::kFloat, fF)
|
||||
NOTIFY_CHECK(plVarDescriptor::kDouble, fD)
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
if (notify)
|
||||
|
Reference in New Issue
Block a user