Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7d14b95f authored by Thomas Wood's avatar Thomas Wood Committed by Dave Airlie
Browse files

drm/edid: fix length check when adding extra 3D modes

parent 1ec2c7fc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2674,7 +2674,7 @@ static int add_3d_struct_modes(struct drm_connector *connector, u16 structure,
	int modes = 0;
	u8 cea_mode;

	if (video_db == NULL || video_index > video_len)
	if (video_db == NULL || video_index >= video_len)
		return 0;

	/* CEA modes are numbered 1..127 */