window.c | 27 ++++++++++++++------------- 1 files changed, 14 insertions(+), 13 deletions(-) Index: window.c =================================================================== RCS file: /cvs/xorg/xc/programs/Xserver/dix/window.c,v retrieving revision 1.8 diff -u -d -r1.8 window.c --- window.c 20 Apr 2005 12:25:19 -0000 1.8 +++ window.c 9 Jun 2005 01:45:14 -0000 @@ -312,23 +312,24 @@ (void)ChangeGC(pGC, GCForeground | GCBackground, attributes); } - ValidateGC((DrawablePtr)pWin->background.pixmap, pGC); - - from = (screenInfo.bitmapBitOrder == LSBFirst) ? _back_lsb : _back_msb; - to = back; - - for (i = 4; i > 0; i--, from++) - for (j = len; j > 0; j--) - *to++ = *from; + ValidateGC((DrawablePtr)pWin->background.pixmap, pGC); - if (blackRoot) - bzero(back, sizeof(back)); + if (blackRoot) + bzero(back, sizeof(back)); + else + { + from = (screenInfo.bitmapBitOrder == LSBFirst) ? _back_lsb : _back_msb; + to = back; - (*pGC->ops->PutImage)((DrawablePtr)pWin->background.pixmap, pGC, 1, - 0, 0, len, 4, 0, XYBitmap, (char *)back); + for (i = 4; i > 0; i--, from++) + for (j = len; j > 0; j--) + *to++ = *from; + } - FreeScratchGC(pGC); + (*pGC->ops->PutImage)((DrawablePtr)pWin->background.pixmap, pGC, 1, + 0, 0, len, 4, 0, XYBitmap, (char *)back); + FreeScratchGC(pGC); } WindowPtr