Skip to contentSkip to conversation

drm/edid: don't return stack garbage from supports_rb

PATCH In review Daniel Vetter 2 participants 3 messages Jun 19, 2012 – Jun 20, 2012

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/edid: don't return stack garbage from supports_rb

We need to initialize this to false, because the is_rb callback only ever sets it to true.

Noticed while reading through the code.

---
 drivers/gpu/drm/drm_edid.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/drm_edid.c +1 -1
index c3b5139..77a436f 100644
@@ -603,7 +603,7 @@ static bool
 drm_monitor_supports_rb(struct edid *edid)
 {
 	if (edid->revision >= 4) {
-		bool ret;
+		bool ret = false;
 		drm_for_each_detailed_block((u8 *)edid, is_rb, &ret);
 		return ret;
 	}
Signature · 1 line
1.7.10
Reviewed-by on v1 1/1
#2 lore raw
In reply to Daniel Vetter
Quoted 8 lines · Daniel Vetter

We need to initialize this to false, because the is_rb callback only ever sets it to true.

Noticed while reading through the code.

- ajax

_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel