From cb330f597f1f281522b99d6de51b14795ba7b51f Mon Sep 17 00:00:00 2001 From: Tobias Doerffel Date: Sat, 18 Aug 2007 21:41:44 +0000 Subject: [PATCH] more checks for not crashing when having arpeggio enabled git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@526 0778d3d1-df1d-0410-868b-ea421aaaa00d --- plugins/lb302/lb302.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/lb302/lb302.cpp b/plugins/lb302/lb302.cpp index 374fbf539..a272c75f4 100644 --- a/plugins/lb302/lb302.cpp +++ b/plugins/lb302/lb302.cpp @@ -779,6 +779,11 @@ void lb302Synth::playNote( notePlayHandle * _n, bool ) ///=== WEIRD CODE FOR MONOPHONIC BEHAVIOUR - BEGIN === /// + if( _n->arpBaseNote() ) + { + return; + } + // number of frames to play - only modified below if we have to play // the rest of an old note fpp_t frames = _n->framesLeftForCurrentPeriod(); @@ -808,7 +813,7 @@ void lb302Synth::playNote( notePlayHandle * _n, bool ) // have to fill up the frames left to the new note so limit // frames to play for not getting into trouble - if( _n != yn ) + if( _n != yn && !yn->arpBaseNote() ) { frames = tMin( frames, yn->offset() - on->offset() ); #ifdef LB_DEBUG