summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichel Dänzer <michel.daenzer@amd.com>2019-01-10 17:03:04 +0100
committerMichel Dänzer <michel@daenzer.net>2019-01-10 17:25:05 +0100
commit2058c4c469b172d4a3b0443f75466d84281a64c7 (patch)
treec0ecf8890aae0c73b4fe3d6c456717a43230f95e /src
parentf3c0939a0cbb93c367ece3d41dc69824f585af42 (diff)
Only call drmmode_validate_leases if RandR is enabled
It would crash if RandR is disabled, e.g. because Xinerama is enabled. Bugzilla: https://bugs.freedesktop.org/109230 (Ported from radeon commit b1c01698f577577e4a88bad0ae08fb5d998e7ebb) Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'src')
-rw-r--r--src/drmmode_display.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index 85a0270..aea53ad 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -3710,7 +3710,8 @@ Bool drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode,
}
/* Validate leases on VT re-entry */
- drmmode_validate_leases(pScrn);
+ if (dixPrivateKeyRegistered(rrPrivKey))
+ drmmode_validate_leases(pScrn);
return TRUE;
}