summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamey Sharp <jamey@minilop.net>2010-05-14 00:18:14 -0700
committerJamey Sharp <jamey@minilop.net>2010-05-14 10:38:29 -0700
commit890f536f8d66f08e7d6a5685659eef4001a8757d (patch)
treed75a61c75824609ba25d07e95f7c7d7c26664456
parent795432d4a92ed5b9fa4d9163e73c8e4fe4c74534 (diff)
Bugfix for "Pre-validate ChangeGC XIDs": off-by-one in loop index.
Signed-off-by: Jamey Sharp <jamey@minilop.net> Tested-by: Colin Harrison <colin.harrison@virgin.net>
-rw-r--r--dix/gc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dix/gc.c b/dix/gc.c
index 00b63bd2d..5a0d00d5a 100644
--- a/dix/gc.c
+++ b/dix/gc.c
@@ -439,7 +439,7 @@ ChangeGCXIDs(ClientPtr client, GC *pGC, BITS32 mask, CARD32 *pC32)
client->errorValue = mask;
return BadValue;
}
- for (i = Ones(mask); i; --i)
+ for (i = Ones(mask); i--; )
vals[i].val = pC32[i];
for (i = 0; i < sizeof(xidfields) / sizeof(*xidfields); ++i)
{