mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-18 08:06:04 +02:00
Remove unnecessary delete statements
If a value is null, the C++ delete statement will do nothing, so there is bo need to explicitly check if the value is null.
This commit is contained in:
parent
43187e233a
commit
5f3329e121
12 changed files with 22 additions and 41 deletions
|
@ -417,11 +417,10 @@ void DSoundManager::ReleaseSounds()
|
|||
void DSoundManager::ReleaseChannels()
|
||||
{
|
||||
for (int i = 0; i < MAX_CHANNELS; i++)
|
||||
if (mPlayingSounds[i] != NULL)
|
||||
{
|
||||
delete mPlayingSounds[i];
|
||||
mPlayingSounds[i] = NULL;
|
||||
}
|
||||
{
|
||||
delete mPlayingSounds[i];
|
||||
mPlayingSounds[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
void DSoundManager::ReleaseFreeChannels()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue