From 898d97672907a8074031d0d1038cd44bb5caf40d Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Mon, 12 Dec 2011 16:49:33 -0800 Subject: [PATCH] verify_internal_event: preserve constness of data pointer All we're using it for is ErrorF calls, so make it a const char * to stop gcc from warning: inpututils.c: In function 'verify_internal_event': inpututils.c:629:9: warning: cast discards qualifiers from pointer target type Signed-off-by: Alan Coopersmith Reviewed-by: Jamey Sharp Reviewed-by: Peter Hutterer --- dix/inpututils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dix/inpututils.c b/dix/inpututils.c index 60f9fa0a8..5e2ab87f9 100644 --- a/dix/inpututils.c +++ b/dix/inpututils.c @@ -626,7 +626,7 @@ void verify_internal_event(const InternalEvent *ev) if (ev && ev->any.header != ET_Internal) { int i; - unsigned char *data = (unsigned char*)ev; + const unsigned char *data = (const unsigned char*)ev; ErrorF("dix: invalid event type %d\n", ev->any.header);