From: Takashi Iwai Date: Fri, 26 Jul 2024 12:46:58 +0000 (+0200) Subject: aseqdump: Correct the limit of UMP 7-bit SysEx bytes X-Git-Tag: v1.2.13~19 X-Git-Url: https://git.alsa-project.org/?a=commitdiff_plain;h=0188f93f022725e6ba38c5b4f7ccec6249a19162;p=alsa-utils.git aseqdump: Correct the limit of UMP 7-bit SysEx bytes UMP 7-bit SysEx can hold up to 6 bytes, not 14 bytes. Fixes: 02b0c3af56bd ("aseqdump: Avoid OOB access with broken SysEx UMP packets") Signed-off-by: Takashi Iwai --- diff --git a/seq/aseqdump/aseqdump.c b/seq/aseqdump/aseqdump.c index 85230df..090373d 100644 --- a/seq/aseqdump/aseqdump.c +++ b/seq/aseqdump/aseqdump.c @@ -698,8 +698,8 @@ static void dump_ump_sysex_event(const unsigned int *ump) dump_ump_sysex_status("SysEx", snd_ump_sysex_msg_status(ump)); length = snd_ump_sysex_msg_length(ump); printf(" length %d ", length); - if (length > 14) - length = 14; + if (length > 6) + length = 6; for (i = 0; i < length; i++) printf("%s%02x", i ? ":" : "", ump_sysex7_data(ump, i)); printf("\n");