[PATCH libX11 3/5] fix: warning: pointer targets in passing argument 2 of '_XSend' differ in signedness [-Wpointer-sign]

walter harms wharms at bfs.de
Tue Apr 26 14:31:27 UTC 2016


fix signess warning by casting
Signed-off-by: walter harms <wharms at bfs.de>


---
 src/ModMap.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/ModMap.c b/src/ModMap.c
index a809aa2..4263a8b 100644
--- a/src/ModMap.c
+++ b/src/ModMap.c
@@ -39,7 +39,7 @@ XGetModifierMapping(register Display *dpy)
     XModifierKeymap *res;

     LockDisplay(dpy);
-    GetEmptyReq(GetModifierMapping, req);
+    GetEmptyReq(GetModifierMapping, req); // Never used ?
     (void) _XReply (dpy, (xReply *)&rep, 0, xFalse);

     if (rep.length < (INT_MAX >> 2)) {
@@ -83,7 +83,7 @@ XSetModifierMapping(
     req->length += mapSize >> 2;
     req->numKeyPerModifier = modifier_map->max_keypermod;

-    Data(dpy, modifier_map->modifiermap, mapSize);
+    Data(dpy, (const char *)modifier_map->modifiermap, mapSize);

     (void) _XReply(dpy, (xReply *) & rep,
 	(SIZEOF(xSetModifierMappingReply) - SIZEOF(xReply)) >> 2, xTrue);
-- 
2.1.4



More information about the xorg-devel mailing list