mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
uwb: Fix handling IEs with empty IE data in uwb_est_get_size()
A DRP notification may sometimes have empty IE data. This patch fixes uwb_est_get_size() so that this case is handled properly. Signed-off-by: Anderson Lizardo <[email protected]> Signed-off-by: David Vrabel <[email protected]>
This commit is contained in:
parent
b0a81328c2
commit
9d839477f8
1 changed files with 1 additions and 1 deletions
|
|
@ -395,7 +395,7 @@ ssize_t uwb_est_get_size(struct uwb_rc *uwb_rc, struct uwb_est *est,
|
|||
case UWB_EST_8: type_size = sizeof(u8); break;
|
||||
default: BUG();
|
||||
}
|
||||
if (offset + type_size >= rceb_size) {
|
||||
if (offset + type_size > rceb_size) {
|
||||
if (printk_ratelimit())
|
||||
dev_err(dev, "EST %p 0x%04x/%04x/%04x[%u]: "
|
||||
"not enough data to read extra size\n",
|
||||
|
|
|
|||
Loading…
Reference in a new issue