Nikolay Sivov : dwrite: Handle failure when getting texture bounds ( Coverity).

Alexandre Julliard julliard at wine.codeweavers.com
Mon Aug 24 07:37:14 CDT 2015


Module: wine
Branch: master
Commit: 3ffe6ab0bb23cdcb2e1915ffd1629bcb288dd61b
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=3ffe6ab0bb23cdcb2e1915ffd1629bcb288dd61b

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Sat Aug 22 21:06:29 2015 +0300

dwrite: Handle failure when getting texture bounds (Coverity).

---

 dlls/dwrite/gdiinterop.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/dlls/dwrite/gdiinterop.c b/dlls/dwrite/gdiinterop.c
index 6f96656..8ef38e2 100644
--- a/dlls/dwrite/gdiinterop.c
+++ b/dlls/dwrite/gdiinterop.c
@@ -401,6 +401,10 @@ static HRESULT WINAPI rendertarget_DrawGlyphRun(IDWriteBitmapRenderTarget1 *ifac
     hr = IDWriteGlyphRunAnalysis_GetAlphaTextureBounds(analysis, DWRITE_TEXTURE_ALIASED_1x1, &bounds);
     if (FAILED(hr) || IsRectEmpty(&bounds)) {
         hr = IDWriteGlyphRunAnalysis_GetAlphaTextureBounds(analysis, DWRITE_TEXTURE_CLEARTYPE_3x1, &bounds);
+        if (FAILED(hr)) {
+            WARN("GetAlphaTextureBounds() failed, 0x%08x\n", hr);
+            return hr;
+        }
         texturetype = DWRITE_TEXTURE_CLEARTYPE_3x1;
     }
 




More information about the wine-cvs mailing list