Fix a panic when checking for magic number in firmware
This commit is contained in:
+2
-2
@@ -215,8 +215,8 @@ impl App {
|
||||
{
|
||||
warn!(
|
||||
"App: SysEx does not start with magic number; first {} bytes = {}. dropping.",
|
||||
MAGIC_NUMBER,
|
||||
sysex[..MAGIC_NUMBER_LEN]
|
||||
MAGIC_NUMBER_LEN.min(sysex.len()),
|
||||
sysex[..MAGIC_NUMBER_LEN.min(sysex.len())]
|
||||
);
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user