[PATCH] winex11.drv: remove more superflous NULL checks (Coverity)

Marcus Meissner marcus at jet.franken.de
Fri Jan 8 02:24:18 CST 2010


Hi,

After yesterdays removal of the initial check, Coverity
sees two more. Remove those checks too.

Ciao, Marcus
---
 dlls/winex11.drv/palette.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winex11.drv/palette.c b/dlls/winex11.drv/palette.c
index a02501f..cbdf2d1 100644
--- a/dlls/winex11.drv/palette.c
+++ b/dlls/winex11.drv/palette.c
@@ -925,7 +925,7 @@ int X11DRV_PALETTE_ToPhysical( X11DRV_PDEVICE *physDev, COLORREF color )
 	    /* fall through to RGB */
 
 	  case 0: /* RGB */
-	    if (physDev && (physDev->depth == 1) )
+	    if (physDev->depth == 1)
 	    {
                 int white = 1;
                 RGBQUAD table[2];
@@ -981,7 +981,7 @@ int X11DRV_PALETTE_ToPhysical( X11DRV_PDEVICE *physDev, COLORREF color )
 		/* fall through to RGB */
 
        	    case 0:  /* RGB */
-		if (physDev && (physDev->depth == 1) )
+		if (physDev->depth == 1)
 		{
                     int white = 1;
                     RGBQUAD table[2];
-- 
1.5.6



More information about the wine-patches mailing list