if (nbytes > 256) { _XEatData(dpy, (unsigned long) nbytes); UnlockDisplay(dpy); SyncHandle(); return 0; }
int XGetPointerMapping (dpy, map, nmaps)    register Display *dpy;    unsigned char *map;	/* RETURN */    int nmaps;{    unsigned char mapping[256];	/* known fixed size */    long nbytes;    xGetPointerMappingReply rep;    register xReq *req;    LockDisplay(dpy);    GetEmptyReq(GetPointerMapping, req);    (void) _XReply(dpy, (xReply *)&rep, 0, xFalse);    nbytes = (long)rep.length << 2;    _XRead (dpy, (char *)mapping, nbytes);    /* don't return more data than the user asked for. */    if (rep.nElts) {	    memcpy ((char *) map, (char *) mapping, 		MIN((int)rep.nElts, nmaps) );	}    UnlockDisplay(dpy);    SyncHandle();    return ((int) rep.nElts);}