1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-16 05:11:49 -05:00

cppcheck fixes

This commit is contained in:
f4exb 2017-05-05 09:30:45 +02:00
parent 7dbaa01256
commit 3fff41ce70
2 changed files with 3 additions and 1 deletions

View File

@ -113,7 +113,9 @@ void FileSourceThread::setBuffer(std::size_t chunksize)
else else
{ {
qDebug() << "FileSourceThread::setBuffer: Re-allocate buffer"; qDebug() << "FileSourceThread::setBuffer: Re-allocate buffer";
quint8 *buf = m_buf;
m_buf = (quint8*) realloc((void*) m_buf, m_bufsize); m_buf = (quint8*) realloc((void*) m_buf, m_bufsize);
if (!m_buf) free(buf);
} }
qDebug() << "FileSourceThread::setBuffer: size: " << m_bufsize qDebug() << "FileSourceThread::setBuffer: size: " << m_bufsize

View File

@ -388,7 +388,7 @@ void MainWindow::loadSettings()
for(int i = 0; i < m_settings.getPresetCount(); ++i) for(int i = 0; i < m_settings.getPresetCount(); ++i)
{ {
addPresetToTree(m_settings.getPreset(i)); ui->presetTree->setCurrentItem(addPresetToTree(m_settings.getPreset(i)));
} }
} }