Use correct delete operator

pull/879/head
Jon Beniston 2021-04-28 15:39:07 +01:00
rodzic 9842e477af
commit 999d5e8af7
2 zmienionych plików z 7 dodań i 8 usunięć

Wyświetl plik

@ -53,7 +53,7 @@ IEEE_802_15_4_ModSource::IEEE_802_15_4_ModSource() :
IEEE_802_15_4_ModSource::~IEEE_802_15_4_ModSource()
{
delete m_sinLUT;
delete[] m_sinLUT;
}
void IEEE_802_15_4_ModSource::pull(SampleVector::iterator begin, unsigned int nbSamples)
@ -406,8 +406,7 @@ void IEEE_802_15_4_ModSource::createHalfSine(int sampleRate, int chipRate)
int samplesPerChip = sampleRate / chipRate;
double tc = 1.0 / chipRate;
if (m_sinLUT)
delete m_sinLUT;
delete[] m_sinLUT;
m_sinLUT = new double[2*samplesPerChip];
for (int i = 0; i < 2*samplesPerChip; i++)
{

Wyświetl plik

@ -47,13 +47,13 @@ DVBS::~DVBS()
{
// Free interleaver FIFO memory
for (int i = 1; i < interleaveDepth; i++)
delete m_interleaveFIFO[i];
delete m_interleaveIdx;
delete m_interleaveLen;
delete m_interleaveFIFO;
delete[] m_interleaveFIFO[i];
delete[] m_interleaveIdx;
delete[] m_interleaveLen;
delete[] m_interleaveFIFO;
// Free packet buffer
delete m_packet;
delete[] m_packet;
}
// Scramble input packet (except for sync bytes) with psuedo random binary sequence