Re: [PATCH] HID: rmi: check report length before trimming sentinel bytes

Jiri Kosina <[email protected]>
Newsgroups gmane.linux.kernel,gmane.linux.kernel.input
Message-ID <[email protected]>
On Tue, 30 Jun 2026, Pengpeng Hou wrote:

> rmi_check_sanity() trims trailing 0xff sentinel bytes, but its loop
> reads data[valid_size - 1] before checking that valid_size is non-zero.
> 
> Reverse the condition so the length is proved before the last byte is
> inspected.

Applied, thanks.

-- 
Jiri Kosina
SUSE Labs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.