Index: reactos/win32ss/gdi/ntgdi/dibobj.c =================================================================== --- reactos/win32ss/gdi/ntgdi/dibobj.c (revision 74405) +++ reactos/win32ss/gdi/ntgdi/dibobj.c (working copy) @@ -1183,7 +1183,7 @@ IN UINT cjMaxBits, IN HANDLE hcmXform) { - BOOL bResult = FALSE; + INT nRet = 0; SIZEL sizel; RECTL rcSrc, rcDst; PDC pdc; @@ -1217,7 +1217,7 @@ if ((sizel.cx == cxSrc) && (sizel.cy == cySrc) && (dwRop == SRCCOPY)) { /* Yes, we can! */ - return NtGdiSetDIBitsToDeviceInternal(hdc, + nRet = NtGdiSetDIBitsToDeviceInternal(hdc, xDst, yDst, cxDst, @@ -1233,6 +1233,9 @@ cjMaxInfo, TRUE, hcmXform); + if (nRet) + nRet = labs(pbmi->bmiHeader.biHeight); + return nRet; } if (pjInit && (cjMaxBits > 0)) @@ -1297,7 +1300,7 @@ if (!hbmTmp) { - bResult = FALSE; + nRet = 0; goto cleanup; } @@ -1304,7 +1307,7 @@ psurfTmp = SURFACE_ShareLockSurface(hbmTmp); if (!psurfTmp) { - bResult = FALSE; + nRet = 0; goto cleanup; } @@ -1312,7 +1315,7 @@ ppalDIB = CreateDIBPalette(pbmi, pdc, dwUsage); if (!ppalDIB) { - bResult = FALSE; + nRet = 0; goto cleanup; } @@ -1330,18 +1333,22 @@ pdc->pdcattr->crForegroundClr); /* Perform the stretch operation */ - bResult = IntEngStretchBlt(&psurfDst->SurfObj, - &psurfTmp->SurfObj, - NULL, - &pdc->co.ClipObj, - &exlo.xlo, - &pdc->dclevel.ca, - &rcDst, - &rcSrc, - NULL, - &pdc->eboFill.BrushObject, - NULL, - WIN32_ROP3_TO_ENG_ROP4(dwRop)); + nRet = IntEngStretchBlt(&psurfDst->SurfObj, + &psurfTmp->SurfObj, + NULL, + &pdc->co.ClipObj, + &exlo.xlo, + &pdc->dclevel.ca, + &rcDst, + &rcSrc, + NULL, + &pdc->eboFill.BrushObject, + NULL, + WIN32_ROP3_TO_ENG_ROP4(dwRop)); + if (nRet) + { + nRet = pbmi->bmiHeader.biHeight; + } /* Cleanup */ DC_vFinishBlit(pdc, NULL); @@ -1353,7 +1360,7 @@ if (pdc) DC_UnlockDc(pdc); if (pvBits) ExFreePoolWithTag(pvBits, 'pmeT'); - return bResult; + return nRet; }