aboutsummaryrefslogtreecommitdiffstats
path: root/lv2
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2020-09-27 18:17:47 +0200
committerDavid Robillard <d@drobilla.net>2020-09-27 18:17:47 +0200
commit9e46d4a8323e9a91480631980a984700b76a09bd (patch)
treebca7eff6274406c79e430917f7d1729e7dad773d /lv2
parent9b9ca021d6401097d32d96d27de6f906a0252109 (diff)
downloadlv2-9e46d4a8323e9a91480631980a984700b76a09bd.tar.xz
Don't use else after return
Diffstat (limited to 'lv2')
-rw-r--r--lv2/midi/midi.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/lv2/midi/midi.h b/lv2/midi/midi.h
index 0abfba1..3a9583b 100644
--- a/lv2/midi/midi.h
+++ b/lv2/midi/midi.h
@@ -216,11 +216,13 @@ static inline LV2_Midi_Message_Type
lv2_midi_message_type(const uint8_t* msg) {
if (lv2_midi_is_voice_message(msg)) {
return (LV2_Midi_Message_Type)(msg[0] & 0xF0);
- } else if (lv2_midi_is_system_message(msg)) {
+ }
+
+ if (lv2_midi_is_system_message(msg)) {
return (LV2_Midi_Message_Type)msg[0];
- } else {
- return LV2_MIDI_MSG_INVALID;
}
+
+ return LV2_MIDI_MSG_INVALID;
}
#ifdef __cplusplus