Skip to content

Commit fc34fbf

Browse files
committed
Fix wrong Device ID in Sysex Universal message parsing
1 parent 3cbc18a commit fc34fbf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/system_exclusive/mod.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -135,14 +135,14 @@ impl SystemExclusiveMsg {
135135
)),
136136
Some(0x7E) => Ok((
137137
Self::UniversalNonRealTime {
138-
device: DeviceID::from_midi(m)?,
138+
device: DeviceID::from_midi(&m[1..])?,
139139
msg: UniversalNonRealTimeMsg::from_midi(&m[2..])?,
140140
},
141141
m.len() + 2,
142142
)),
143143
Some(0x7F) => Ok((
144144
Self::UniversalRealTime {
145-
device: DeviceID::from_midi(m)?,
145+
device: DeviceID::from_midi(&m[1..])?,
146146
msg: UniversalRealTimeMsg::from_midi(&m[2..], ctx)?,
147147
},
148148
m.len() + 2,

0 commit comments

Comments
 (0)