mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-01-11 15:39:36 -05:00
Fixed crash and memory leak in the AudioWizard of the VOIP plugin.
Please use at least Qt 4.6.4 when compiling RetrosShare with the VOIP plugin because of the fix of the bug QTBUG-11883. git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5603 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
54f0c208df
commit
e6db506cb2
@ -276,8 +276,7 @@ void AudioInputConfig::emptyBuffer() {
|
||||
}
|
||||
|
||||
void AudioInputConfig::on_qpbAudioWizard_clicked() {
|
||||
AudioWizard *aw = new AudioWizard(this);
|
||||
aw->exec();
|
||||
delete aw;
|
||||
AudioWizard aw(this);
|
||||
aw.exec();
|
||||
loadSettings();
|
||||
}
|
||||
|
@ -41,11 +41,28 @@
|
||||
|
||||
AudioWizard::~AudioWizard()
|
||||
{
|
||||
if (ticker) {
|
||||
ticker->stop();
|
||||
}
|
||||
if (inputDevice) {
|
||||
inputDevice->stop();
|
||||
delete(inputDevice);
|
||||
inputDevice = NULL;
|
||||
}
|
||||
if (inputProcessor) {
|
||||
inputProcessor->close();
|
||||
delete(inputProcessor);
|
||||
inputProcessor = NULL;
|
||||
}
|
||||
if (outputDevice) {
|
||||
outputDevice->stop();
|
||||
delete(outputDevice);
|
||||
outputDevice = NULL;
|
||||
}
|
||||
if (outputProcessor) {
|
||||
outputProcessor->close();
|
||||
delete(outputProcessor);
|
||||
outputProcessor = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -95,7 +95,9 @@ SpeexInputProcessor::SpeexInputProcessor(QObject *parent) : QIODevice(parent),
|
||||
}
|
||||
|
||||
SpeexInputProcessor::~SpeexInputProcessor() {
|
||||
if (preprocessor) {
|
||||
speex_preprocess_state_destroy(preprocessor);
|
||||
}
|
||||
if (echo_state) {
|
||||
speex_echo_state_destroy(echo_state);
|
||||
}
|
||||
|
@ -62,8 +62,10 @@ AppearancePage::AppearancePage(QWidget * parent, Qt::WFlags flags)
|
||||
|
||||
AppearancePage::~AppearancePage()
|
||||
{
|
||||
/* reaload style sheet */
|
||||
Rshare::loadStyleSheet(Settings->getSheetName());
|
||||
if (wasLoaded()) {
|
||||
/* reaload style sheet */
|
||||
Rshare::loadStyleSheet(Settings->getSheetName());
|
||||
}
|
||||
}
|
||||
|
||||
/** Saves the changes on this page */
|
||||
|
Loading…
Reference in New Issue
Block a user