Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 139be681 authored by Robert Wu's avatar Robert Wu
Browse files

USB MIDI: Don't call openLocked on device unplug

When a USB MIDI device with multiple ports is
unplugged, onDeviceStatusChanged gets called
multiple times. The first time ends up opening a
port since there are still other open ports.

The fix here is to ignore onDeviceStatusChanged()
if close() was called before.

Also changed a continue to a break since that
condition almost never gets hit.

Bug: 232142589
Bug: 231496864
Test: Midi Keyboard that opens both input and output
for both peripheral and host mode

Change-Id: I973d55371cd16803ede192081531ca5f59847a51
parent 9228e501
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment