Replace SAFE_DELETE / SAFE_DELETE_ARRAY macros

SAFE_DELETE -> RageUtil::SafeDelete
SAFE_DELETE_ARRAY -> RageUtil::SafeDeleteArray

Update JsonUtil.h to include RageUtil.h - MSVC doesn't need it included for some reason, but GCC and XCode does.
This commit is contained in:
sukibaby
2024-09-30 15:13:32 -07:00
committed by teejusb
parent cff063cd21
commit abf89ec2b1
62 changed files with 193 additions and 178 deletions
+3 -3
View File
@@ -47,7 +47,7 @@ void TimingData::Clear()
std::vector<TimingSegment*> &vSegs = m_avpTimingSegments[tst];
for( unsigned i = 0; i < vSegs.size(); ++i )
{
SAFE_DELETE( vSegs[i] );
RageUtil::SafeDelete( vSegs[i] );
}
vSegs.clear();
@@ -589,7 +589,7 @@ static void EraseSegment( std::vector<TimingSegment*> &vSegs, int index, TimingS
#endif
vSegs.erase( vSegs.begin() + index );
SAFE_DELETE( cur );
RageUtil::SafeDelete( cur );
}
// NOTE: the pointer we're passed is a reference to a temporary,
@@ -730,7 +730,7 @@ void TimingData::AddSegment( const TimingSegment *seg )
if( bOnSameRow )
{
// delete the existing pointer and replace it
SAFE_DELETE( cur );
RageUtil::SafeDelete( cur );
vSegs[index] = cpy;
}
else