xf86-video-ati: Branch 'master'

Alex Deucher agd5f at kemper.freedesktop.org
Tue Mar 11 18:20:44 PDT 2008


 src/radeon_exa_render.c |   18 ++++++++++++------
 1 file changed, 12 insertions(+), 6 deletions(-)

New commits:
commit d4446461c3630caff166456c351ace34f57cc119
Author: Matt Turner <mattst88 at gmail.com>
Date:   Tue Mar 11 21:20:53 2008 -0400

    Properly fix uninitialized variables warnings
    
    According to commit 9fd13e6773371c82b9799a5bda7c96ffa5cafe8c to
    xf86-video-intel by Kristian Høgsberg, there is a better way to fix the
    possibly initialized variables warnings. This patch will use Kristian's fix.

diff --git a/src/radeon_exa_render.c b/src/radeon_exa_render.c
index 72bc38d..31e1206 100644
--- a/src/radeon_exa_render.c
+++ b/src/radeon_exa_render.c
@@ -425,7 +425,7 @@ static Bool FUNC_NAME(R100PrepareComposite)(int op,
 					    PixmapPtr pDst)
 {
     RINFO_FROM_SCREEN(pDst->drawable.pScreen);
-    CARD32 dst_format = 0, dst_offset, dst_pitch, colorpitch;
+    CARD32 dst_format, dst_offset, dst_pitch, colorpitch;
     CARD32 pp_cntl, blendcntl, cblend, ablend;
     int pixel_shift;
     ACCEL_PREAMBLE();
@@ -435,7 +435,9 @@ static Bool FUNC_NAME(R100PrepareComposite)(int op,
     if (!info->XInited3D)
 	RADEONInit3DEngine(pScrn);
 
-    RADEONGetDestFormat(pDstPicture, &dst_format);
+    if (!RADEONGetDestFormat(pDstPicture, &dst_format))
+    	return FALSE;
+
     pixel_shift = pDst->drawable.bitsPerPixel >> 4;
 
     dst_offset = exaGetPixmapOffset(pDst) + info->fbLocation;
@@ -707,7 +709,7 @@ static Bool FUNC_NAME(R200PrepareComposite)(int op, PicturePtr pSrcPicture,
 				PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
 {
     RINFO_FROM_SCREEN(pDst->drawable.pScreen);
-    CARD32 dst_format = 0, dst_offset, dst_pitch;
+    CARD32 dst_format, dst_offset, dst_pitch;
     CARD32 pp_cntl, blendcntl, cblend, ablend, colorpitch;
     int pixel_shift;
     ACCEL_PREAMBLE();
@@ -717,7 +719,9 @@ static Bool FUNC_NAME(R200PrepareComposite)(int op, PicturePtr pSrcPicture,
     if (!info->XInited3D)
 	RADEONInit3DEngine(pScrn);
 
-    RADEONGetDestFormat(pDstPicture, &dst_format);
+    if (!RADEONGetDestFormat(pDstPicture, &dst_format))
+    	return FALSE;
+
     pixel_shift = pDst->drawable.bitsPerPixel >> 4;
 
     dst_offset = exaGetPixmapOffset(pDst) + info->fbLocation;
@@ -1030,7 +1034,7 @@ static Bool FUNC_NAME(R300PrepareComposite)(int op, PicturePtr pSrcPicture,
 				PixmapPtr pSrc, PixmapPtr pMask, PixmapPtr pDst)
 {
     RINFO_FROM_SCREEN(pDst->drawable.pScreen);
-    CARD32 dst_format = 0, dst_offset, dst_pitch;
+    CARD32 dst_format, dst_offset, dst_pitch;
     CARD32 txenable, colorpitch;
     CARD32 blendcntl;
     int pixel_shift;
@@ -1044,7 +1048,9 @@ static Bool FUNC_NAME(R300PrepareComposite)(int op, PicturePtr pSrcPicture,
     if (!info->XInited3D)
 	RADEONInit3DEngine(pScrn);
 
-    R300GetDestFormat(pDstPicture, &dst_format);
+    if (!R300GetDestFormat(pDstPicture, &dst_format))
+    	return FALSE;
+
     pixel_shift = pDst->drawable.bitsPerPixel >> 4;
 
     dst_offset = exaGetPixmapOffset(pDst) + info->fbLocation;


More information about the xorg-commit mailing list