78569: Subject: [1/2]usp10: respect the presence or absence of the SSA_BREAK flag

buildbot at kegel.com buildbot at kegel.com
Thu Sep 8 18:00:01 CDT 2011


This is an experimental automated build and test service.
Please feel free to ignore this email while we work the kinks out.

The Buildbot has detected a failed build on builder runtests-heaptest while building Wine.
Full details are available at: http://buildbot.kegel.com/builders/runtests-heaptest/builds/6 (though maybe not for long, as I'm still reinstalling the buildbot periodically while experimenting)
BUILD FAILED: failed shell_3


For more info about this message, see http://wiki.winehq.org/BuildBot


-------------- next part --------------
From: Aric Stewart <aric at codeweavers.com>
Subject: [1/2]usp10: respect the presence or absence of the SSA_BREAK flag
Message-Id: <4E69004B.7040105 at codeweavers.com>
Date: Thu, 08 Sep 2011 12:50:03 -0500

---
  dlls/usp10/usp10.c |   17 +++++++++++++----
  1 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/dlls/usp10/usp10.c b/dlls/usp10/usp10.c
index 873d10b..e2a1756 100644
--- a/dlls/usp10/usp10.c
+++ b/dlls/usp10/usp10.c
@@ -324,6 +324,7 @@ typedef struct {
 
 typedef struct {
     HDC hdc;
+    DWORD dwFlags;
     BOOL invalid;
     int clip_len;
     ScriptCache *sc;
@@ -931,6 +932,7 @@ HRESULT WINAPI ScriptStringAnalyse(HDC hdc, const void *pString, int cString,
     /* FIXME: handle clipping */
     analysis->clip_len = cString;
     analysis->hdc = hdc;
+    analysis->dwFlags = dwFlags;
 
     if (psState)
         sState = *psState;
@@ -959,10 +961,16 @@ HRESULT WINAPI ScriptStringAnalyse(HDC hdc, const void *pString, int cString,
     }
     if (hr != S_OK) goto error;
 
-    if ((analysis->logattrs = heap_alloc(sizeof(SCRIPT_LOGATTR) * cString)))
-        ScriptBreak(pString, cString, (SCRIPT_STRING_ANALYSIS)analysis, analysis->logattrs);
-    else
-        goto error;
+    if (dwFlags & SSA_BREAK)
+    {
+        if ((analysis->logattrs = heap_alloc(sizeof(SCRIPT_LOGATTR) * cString)))
+        {
+            for (i = 0; i < analysis->numItems; i++)
+                ScriptBreak(&((LPWSTR)pString)[analysis->pItem[i].iCharPos], analysis->pItem[i+1].iCharPos - analysis->pItem[i].iCharPos, &analysis->pItem[i].a, &analysis->logattrs[analysis->pItem[i].iCharPos]);
+        }
+        else
+            goto error;
+    }
 
     if (!(analysis->glyphs = heap_alloc_zero(sizeof(StringGlyphs) * analysis->numItems)))
         goto error;
@@ -2351,6 +2359,7 @@ const SCRIPT_LOGATTR * WINAPI ScriptString_pLogAttr(SCRIPT_STRING_ANALYSIS ssa)
     TRACE("(%p)\n", ssa);
 
     if (!analysis) return NULL;
+    if (!(analysis->dwFlags & SSA_BREAK)) return NULL;
     return analysis->logattrs;
 }
 



More information about the wine-tests-results mailing list