diff options
Diffstat (limited to 'xorg-server/randr/rrscreen.c')
-rw-r--r-- | xorg-server/randr/rrscreen.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/xorg-server/randr/rrscreen.c b/xorg-server/randr/rrscreen.c index 4c7d35678..dceb32f2e 100644 --- a/xorg-server/randr/rrscreen.c +++ b/xorg-server/randr/rrscreen.c @@ -669,8 +669,9 @@ ProcRRGetScreenInfo (ClientPtr client) rep.sizeID = pData->size; rep.rate = pData->refresh; - extraLen = (rep.nSizes * sizeof (xScreenSizes) + - rep.nrateEnts * sizeof (CARD16)); + extraLen = rep.nSizes * sizeof (xScreenSizes); + if (has_rate) + extraLen += rep.nrateEnts * sizeof (CARD16); if (extraLen) { |