summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUri Lublin <uril@redhat.com>2013-01-17 16:26:33 +0200
committerAlon Levy <alevy@redhat.com>2013-01-20 11:58:50 +0200
commit3963ad1a140ef4b2a3f09471d0135311b9b36c87 (patch)
treecbef026e445fe17d15789e866e4e6defc987943c
parent1d5001116662ef832e010a098a68b81446c1c531 (diff)
qxl_driver: check_crtc: handle qxl->crtcs == NULL
-rw-r--r--src/qxl_driver.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/qxl_driver.c b/src/qxl_driver.c
index 1a253d2..d8abb7b 100644
--- a/src/qxl_driver.c
+++ b/src/qxl_driver.c
@@ -1040,6 +1040,10 @@ check_crtc (qxl_screen_t *qxl)
int i, count = 0;
xf86CrtcPtr crtc;
+ if (qxl->crtcs == NULL) {
+ return 0;
+ }
+
for (i = 0 ; i < qxl->num_heads; ++i)
{
crtc = qxl->crtcs[i];