diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-12-12 16:49:33 -0800 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2011-12-12 17:03:09 -0800 |
commit | 020d83d361b0ab54ac962e97b12935be785f9a67 (patch) | |
tree | da6d40414db54d7551768315fd5f97cb25bdcf3a /Xext/xres.c | |
parent | 2ddae8f0bd2a9ce0cd15bf3848393af29e615acf (diff) |
xres.c: Preserve constness of string returned by LookupResourceName
MakeAtom now accepts a const char * so we don't need to cast down to
char * anymore. Fixes gcc warning of:
xres.c: In function 'ProcXResQueryClientResources':
xres.c:155:6: warning: cast discards qualifiers from pointer target type
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'Xext/xres.c')
-rw-r--r-- | Xext/xres.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Xext/xres.c b/Xext/xres.c index b95272882..232fbab5b 100644 --- a/Xext/xres.c +++ b/Xext/xres.c @@ -147,12 +147,12 @@ ProcXResQueryClientResources (ClientPtr client) if(num_types) { xXResType scratch; - char *name; + const char *name; for(i = 0; i < lastResourceType; i++) { if(!counts[i]) continue; - name = (char *)LookupResourceName(i + 1); + name = LookupResourceName(i + 1); if (strcmp(name, XREGISTRY_UNKNOWN)) scratch.resource_type = MakeAtom(name, strlen(name), TRUE); else { |