diff options
author | Maarten Lankhorst <maarten.lankhorst@canonical.com> | 2013-03-26 15:19:52 +0100 |
---|---|---|
committer | Maarten Lankhorst <maarten.lankhorst@canonical.com> | 2013-03-26 15:19:52 +0100 |
commit | 3c631228a9f57e73ee693d5283894db1a460e0a4 (patch) | |
tree | 33854d7365f1d3c4efe93f04d7bde016c31ece15 | |
parent | e5b5297ac449fb4ac62cc6471f933ae2265778a2 (diff) |
modesetting: return null for get_modes if output could not be retrieved
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
-rw-r--r-- | src/drmmode_display.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c index e8ebef1..2dc7576 100644 --- a/src/drmmode_display.c +++ b/src/drmmode_display.c @@ -709,6 +709,9 @@ drmmode_output_get_modes(xf86OutputPtr output) drmModePropertyPtr props; xf86MonPtr mon = NULL; + if (!koutput) + return NULL; + /* look for an EDID property */ for (i = 0; i < koutput->count_props; i++) { props = drmModeGetProperty(drmmode->fd, koutput->props[i]); |