From e733042cdbc29b3837448b36db190c6df1e83d35 Mon Sep 17 00:00:00 2001 From: Vesa Date: Sat, 14 Jun 2014 17:42:00 +0300 Subject: [PATCH] FxMixer: clearChannel had the same erroneous for loop as deleteChannel --- src/core/FxMixer.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/core/FxMixer.cpp b/src/core/FxMixer.cpp index 02a6d3d8a..961d6f8d6 100644 --- a/src/core/FxMixer.cpp +++ b/src/core/FxMixer.cpp @@ -538,9 +538,9 @@ void FxMixer::clearChannel(fx_ch_t index) if( index > 0) { // delete existing sends - for( int i=0; im_sends.size(); ++i) + while( ! ch->m_sends.isEmpty() ) { - deleteChannelSend(index, ch->m_sends[i]); + deleteChannelSend( index, ch->m_sends.first() ); } // add send to master @@ -548,11 +548,10 @@ void FxMixer::clearChannel(fx_ch_t index) } // delete receives - for( int i=0; im_receives.size(); ++i) + while( ! ch->m_receives.isEmpty() ) { - deleteChannelSend(ch->m_receives[i], index); + deleteChannelSend( ch->m_receives.first(), index ); } - } void FxMixer::saveSettings( QDomDocument & _doc, QDomElement & _this )