summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2011-12-12 16:49:32 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2011-12-12 17:04:03 -0800
commit99dfe9b1de09cb481e95bd4c45dcf7493480798b (patch)
tree478e552de686a384a8207216ff52c7e9b28ce538
parentdd80156bf05c9eb4000d0981e00d0d9fb69a94f6 (diff)
Fix deconstifying cast warning in xi2_get_type
Since we're just comparing values in the struct, cast it to a const xGenericEvent * to clear gcc warning of: events.c: In function 'xi2_get_type': events.c:193:5: 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>
-rw-r--r--dix/events.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/dix/events.c b/dix/events.c
index 59caa918f..5c0f9ddaf 100644
--- a/dix/events.c
+++ b/dix/events.c
@@ -190,7 +190,7 @@ core_get_type(const xEvent *event)
static inline int
xi2_get_type(const xEvent *event)
{
- xGenericEvent* e = (xGenericEvent*)event;
+ const xGenericEvent* e = (const xGenericEvent*)event;
return (e->type != GenericEvent || e->extension != IReqCode) ? 0 : e->evtype;
}