summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2016-09-23 14:11:52 +0300
committerAdam Jackson <ajax@redhat.com>2016-09-28 14:53:39 -0400
commit380c2ca25ec4dd330f938e382ff4af60bc253785 (patch)
tree7301bc7c823786fcc8336c8b9dde0e12b8adfe42
parent220d327ee00ec1278d50d4ba8cd20612e8b77c8f (diff)
XF86VidMode: Fix free() on walked pointer
Based on: https://patchwork.freedesktop.org/patch/85636/ Rewritten to just not walk the pointer. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Emi Velikov <emil.l.velikov@gmail.com>
-rw-r--r--Xext/vidmode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Xext/vidmode.c b/Xext/vidmode.c
index 499a2a841..ea3ad1320 100644
--- a/Xext/vidmode.c
+++ b/Xext/vidmode.c
@@ -1364,7 +1364,7 @@ ProcVidModeGetDotClocks(ClientPtr client)
WriteToClient(client, sizeof(xXF86VidModeGetDotClocksReply), &rep);
if (!ClockProg) {
for (n = 0; n < numClocks; n++) {
- dotclock = *Clocks++;
+ dotclock = Clocks[n];
if (client->swapped) {
WriteSwappedDataToClient(client, 4, (char *) &dotclock);
}