[PATCH 1/5] resource: Remove a useless iteration
Adam Jackson
ajax at redhat.com
Fri Jan 7 11:27:25 PST 2011
Signed-off-by: Adam Jackson <ajax at redhat.com>
---
dix/resource.c | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/dix/resource.c b/dix/resource.c
index 6bd2403..07fcc65 100644
--- a/dix/resource.c
+++ b/dix/resource.c
@@ -382,7 +382,6 @@ GetXIDRange(int client, Bool server, XID *minp, XID *maxp)
XID id, maxid;
ResourcePtr *resp;
ResourcePtr res;
- int i;
XID goodid;
id = (Mask)client << CLIENTOFFSET;
@@ -390,8 +389,8 @@ GetXIDRange(int client, Bool server, XID *minp, XID *maxp)
id |= client ? SERVER_BIT : SERVER_MINID;
maxid = id | RESOURCE_ID_MASK;
goodid = 0;
- for (resp = clientTable[client].resources, i = clientTable[client].buckets;
- --i >= 0;)
+ resp = clientTable[client].resources;
+ if (clientTable[client].buckets)
{
for (res = *resp++; res; res = res->next)
{
--
1.7.3.1
More information about the xorg-devel
mailing list