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

Commit ff6fdbed authored by Maarten Maathuis's avatar Maarten Maathuis Committed by Dave Airlie
Browse files

drm/crtc_helper: avoid NULL-pointer dereference when encoder is NULL

parent 9c552dd7
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -842,6 +842,7 @@ int drm_crtc_helper_set_config(struct drm_mode_set *set)
			/* If the encoder is reused for another connector, then
			 * the appropriate crtc will be set later.
			 */
			if (connector->encoder)
				connector->encoder->crtc = NULL;
			connector->encoder = new_encoder;
		}