We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent dcbaf70 commit cebc669Copy full SHA for cebc669
src/core/NotePlayHandle.cpp
@@ -199,7 +199,12 @@ void NotePlayHandle::play( sampleFrame * _working_buffer )
199
200
lock();
201
202
- if( m_totalFramesPlayed == 0 && !m_hasMidiNote
+ /* It is possible for NotePlayHandle::noteOff to be called before NotePlayHandle::play,
203
+ * which results in a note-on message being sent without a subsequent note-off message.
204
+ * Therefore, we check here whether the note has already been released before sending
205
+ * the note-on message. */
206
+ if( !m_released
207
+ && m_totalFramesPlayed == 0 && !m_hasMidiNote
208
&& ( hasParent() || ! m_instrumentTrack->isArpeggioEnabled() ) )
209
{
210
m_hasMidiNote = true;
0 commit comments