mirror of
https://xff.cz/git/u-boot/
synced 2025-09-30 23:11:32 +02:00
edid: Use sizeof() in cea_is_hdmi_vsdb_present()
We should not use an open-coded value here. Use sizeof() instead.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reported-by: Coverity (CID: 163252)
Fixes: 43c6bdd0
(edid: Add HDMI flag to timing info)
This commit is contained in:
@@ -148,8 +148,8 @@ static bool cea_is_hdmi_vsdb_present(struct edid_cea861_info *info)
|
|||||||
/* check for end of data block */
|
/* check for end of data block */
|
||||||
end = info->dtd_offset;
|
end = info->dtd_offset;
|
||||||
if (end == 0)
|
if (end == 0)
|
||||||
end = 127;
|
end = sizeof(info->data);
|
||||||
if (end < 4 || end > 127)
|
if (end < 4 || end > sizeof(info->data))
|
||||||
return false;
|
return false;
|
||||||
end -= 4;
|
end -= 4;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user