diff options
author | marha <marha@users.sourceforge.net> | 2010-05-25 15:13:57 +0000 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2010-05-25 15:13:57 +0000 |
commit | fb91c8589937f1a9aba5d5a4e0de98c381dfe9b8 (patch) | |
tree | a5c9d127cfb068a107b604ffebf95df291e974b7 /xorg-server/dix/gc.c | |
parent | 4d1b98ace5efb02c14c7a4e36fc2698a1e00b66f (diff) | |
download | vcxsrv-fb91c8589937f1a9aba5d5a4e0de98c381dfe9b8.tar.gz vcxsrv-fb91c8589937f1a9aba5d5a4e0de98c381dfe9b8.tar.bz2 vcxsrv-fb91c8589937f1a9aba5d5a4e0de98c381dfe9b8.zip |
Solved possible crash in debug version (could be a general problem???)
Diffstat (limited to 'xorg-server/dix/gc.c')
-rw-r--r-- | xorg-server/dix/gc.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/xorg-server/dix/gc.c b/xorg-server/dix/gc.c index d39a5a76a..e50c6319b 100644 --- a/xorg-server/dix/gc.c +++ b/xorg-server/dix/gc.c @@ -321,10 +321,30 @@ ChangeGC(ClientPtr client, GC *pGC, BITS32 mask, ChangeGCValPtr pUnion) break;
}
case GCClipXOrigin:
+ #ifndef _DEBUG
NEXTVAL(INT16, pGC->clipOrg.x);
+ #else
+ {
+ long Val;
+ NEXTVAL(long, Val);
+ if (abs(Val)>32767)
+ ErrorF("Value received for GCClipXOrigin is too large %x\n",Val);
+ pGC->clipOrg.x=(INT16)(Val&0xffff);
+ }
+ #endif
break;
case GCClipYOrigin:
+ #ifndef _DEBUG
NEXTVAL(INT16, pGC->clipOrg.y);
+ #else
+ {
+ long Val;
+ NEXTVAL(long, Val);
+ if (abs(Val)>32767)
+ ErrorF("Value received for GCClipYOrigin is too large %x\n",Val);
+ pGC->clipOrg.y=(INT16)(Val&0xffff);
+ }
+ #endif
break;
case GCClipMask:
NEXT_PTR(PixmapPtr, pPixmap);
|