summaryrefslogtreecommitdiff
path: root/src/radeon_dri2.c
diff options
context:
space:
mode:
authorMichel Dänzer <mdaenzer@redhat.com>2021-03-26 17:37:53 +0100
committerMichel Dänzer <michel@daenzer.net>2021-03-26 17:42:50 +0100
commit77d9ab03ca20e683be4c40ccc879e201b538f7e5 (patch)
tree9b14b6e6340418e81283723810986a69d5cd0f12 /src/radeon_dri2.c
parent3c7c84ed49564907a148ae99b03200e0be350060 (diff)
Guard local variable info only used with glamor
Fixes compiler warning with glamor disabled: radeon_dri2.c: In function 'radeon_dri2_exchange_buffers': radeon_dri2.c:732:19: error: unused variable 'info' [-Werror=unused-variable] RADEONInfoPtr info = RADEONPTR(xf86ScreenToScrn(screen)); ^~~~
Diffstat (limited to 'src/radeon_dri2.c')
-rw-r--r--src/radeon_dri2.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/radeon_dri2.c b/src/radeon_dri2.c
index 66a223d8..17983779 100644
--- a/src/radeon_dri2.c
+++ b/src/radeon_dri2.c
@@ -728,8 +728,9 @@ radeon_dri2_exchange_buffers(DrawablePtr draw, DRI2BufferPtr front, DRI2BufferPt
{
struct dri2_buffer_priv *front_priv = front->driverPrivate;
struct dri2_buffer_priv *back_priv = back->driverPrivate;
- ScreenPtr screen = draw->pScreen;
- RADEONInfoPtr info = RADEONPTR(xf86ScreenToScrn(screen));
+#ifdef USE_GLAMOR
+ RADEONInfoPtr info = RADEONPTR(xf86ScreenToScrn(draw->pScreen));
+#endif
RegionRec region;
int tmp;