Skip to content

Commit

Permalink
Ensure midi port exists before removing
Browse files Browse the repository at this point in the history
  • Loading branch information
zonkmachine committed Jul 3, 2017
1 parent 21caf2b commit 13e65b7
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/core/midi/MidiClient.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,11 @@ void MidiClient::addPort( MidiPort* port )

void MidiClient::removePort( MidiPort* port )
{
if( ! port )
{
return;
}

QVector<MidiPort *>::Iterator it =
qFind( m_midiPorts.begin(), m_midiPorts.end(), port );
if( it != m_midiPorts.end() )
Expand Down

0 comments on commit 13e65b7

Please sign in to comment.