sna: Tell valgrind about the returned mode list
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 18 Nov 2013 14:16:07 +0000 (14:16 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 18 Nov 2013 14:16:07 +0000 (14:16 +0000)
Reported-by: Zdenek Kabelac <zkabelac@redhat.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
src/sna/sna_display.c

index 889019c..8982d6a 100644 (file)
@@ -1919,6 +1919,7 @@ sna_output_detect(xf86OutputPtr output)
                        sna_output->num_modes = min(old_count, sna_output->num_modes);
                        break;
                }
+               VG(VALGRIND_MAKE_MEM_DEFINED(sna_output->modes, sizeof(*sna_output->modes)*sna_output->num_modes));
        }
 
        DBG(("%s(%s): found %d modes, connection status=%d\n",