From 8b99b4b1c02f717a02077253b1b5b3b63d31733e Mon Sep 17 00:00:00 2001 From: Filip Navara Date: Fri, 30 Apr 2004 23:42:20 +0000 Subject: [PATCH] - Avoid potencial access violation. Might fix bug #297. svn path=/trunk/; revision=9256 --- reactos/subsys/win32k/dib/dib8bpp.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/reactos/subsys/win32k/dib/dib8bpp.c b/reactos/subsys/win32k/dib/dib8bpp.c index a813c04f5aa..c83aff8701b 100644 --- a/reactos/subsys/win32k/dib/dib8bpp.c +++ b/reactos/subsys/win32k/dib/dib8bpp.c @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: dib8bpp.c,v 1.23 2004/04/25 11:34:12 weiden Exp $ */ +/* $Id: dib8bpp.c,v 1.24 2004/04/30 23:42:20 navaraf Exp $ */ #undef WIN32_LEAN_AND_MEAN #include #include @@ -368,9 +368,10 @@ DIB_8BPP_BitBlt(SURFOBJ *DestSurf, SURFOBJ *SourceSurf, if (i < DestRect->right) { - Dest = *DestBits; for (; i < DestRect->right; i++) { + Dest = DIB_8BPP_GetPixel(DestSurf, i, j); + if (UsesSource) { Source = DIB_GetSource(SourceSurf, SourceGDI, sx + (i - DestRect->left), sy, ColorTranslation); @@ -382,7 +383,6 @@ DIB_8BPP_BitBlt(SURFOBJ *DestSurf, SURFOBJ *SourceSurf, } DIB_8BPP_PutPixel(DestSurf, i, j, DIB_DoRop(Rop4, Dest, Source, Pattern) & 0xFFFF); - Dest >>= 8; } }