don't try to delete the bitmap object in case of failure as it doesn't belong to...
authorChristoph von Wittich <christoph_vw@reactos.org>
Wed, 23 Jan 2008 17:34:06 +0000 (17:34 +0000)
committerChristoph von Wittich <christoph_vw@reactos.org>
Wed, 23 Jan 2008 17:34:06 +0000 (17:34 +0000)
svn path=/trunk/; revision=31962

reactos/dll/win32/user32/misc/desktop.c

index fa60ecf..400cc61 100644 (file)
@@ -413,11 +413,7 @@ SystemParametersInfoW(UINT uiAction,
 
       /* Set the wallpaper bitmap */
       if(!NtUserSystemParametersInfo(SPI_SETDESKWALLPAPER, 0, &hNewWallpaper, fWinIni & SPIF_SENDCHANGE))
-      {
-        if(hNewWallpaper != NULL)
-          DeleteObject(hNewWallpaper);
         return FALSE;
-      }
       /* Do not use the bitmap handle anymore, it doesn't belong to our process anymore! */
       Ret = TRUE;
       if(fWinIni & SPIF_UPDATEINIFILE)